Got one of the sort and print functions working