added sort to linkedlist