@courselist = sort {$$a[n] cmp $$b[n]} @courselist;