My java solution with a hashmap
 public void reorderList(ListNode head) {\n    \t        \n    \t    HashMap <Integer,ListNode> nodeMap = new HashMap<Integer,ListNode> ();\n    \t    int len =
     public void reorderList(ListNode head) {\n    \t        \n    \t    HashMap <Integer,ListNode> nodeMap = new HashMap<Integer,ListNode> ();\n    \t    int len = 0 ;\n    \t    ListNode p = head ; \n    \t    \n    \t    while (p != null) {\n    \t    \tnodeMap.put(len++, p);\n    \t    \tp = p.next ;\n    \t    }\n    \t   \n    \t    \n    \t    int i = 0 ; \n    \t    int j = len - 1 ;\n    \t    for (; i < j - 1 ; ++i ,--j) {\t    \t\n    \t    \tListNode tmp = nodeMap.get(i).next ;\n    \t    \tnodeMap.get(i).next = nodeMap.get(j);\n    \t    \tnodeMap.get(j).next = tmp ;\n    \t    \tnodeMap.get(j - 1).next = null;\n    \t    \t\n    \t    }
[]