Homework for sorting problems