@@ -0,0 +1,1253 @@
+package com.vikramr.algorithms;%0A%0A/**************************************************************************/%0A/**%0A * @author Vikram Raman%0A */%0A%0Aprivate class ListNode %7B%0A    public int val;%0A    public ListNode next;%0A    ListNode(int x) %7B val = x; next = null; %7D%0A%7D%0A %0Apublic class Solution %7B%0A%09public ListNode insertionSortList(ListNode a) %7B%0A%09    if (a == null %7C%7C a.next == null)%0A%09    %7B%0A%09        return a;%0A%09    %7D%0A%09    %0A%09    ListNode head = null;%0A%09    %0A%09    while (a != null)%0A%09    %7B%0A%09        if (head == null)%0A%09        %7B%0A%09            head = a;%0A%09            a = a.next;%0A%09            head.next = null;%0A%09        %7D%0A%09        else%0A%09        %7B%0A%09            ListNode prev = null;%0A%09            ListNode p = head;%0A%09            int val = a.val;%0A%09            %0A%09            while (p != null && val %3E p.val)%0A%09            %7B%0A%09                prev = p;%0A%09                p = p.next;%0A%09            %7D%0A%09            %0A%09            if (prev == null)%0A%09            %7B%0A%09                prev = a;%0A%09                a = a.next;%0A%09                prev.next = p;%0A%09                head = prev;%0A%09            %7D%0A%09            else%0A%09            %7B%0A%09                prev.next = a;%0A%09                a = a.next;%0A    %09            prev.next.next = p;%0A%09            %7D%0A%09        %7D%0A%09    %7D%0A%09    return head;%0A%09%7D%0A%7D%0A

Create LinkedInsertionSort.java