# "Runtime Error", would someone pleased tell me why?

• public class Solution {

class Node{
ListNode listNode;
int num;
Node(ListNode listNode, int num){
this.listNode = listNode;
this.num = num;
}
}

class ListNode implements Cloneable {
int val;
ListNode next;
ListNode(int x) {
val = x;
next = null;
}

``````ListNode mclone() throws CloneNotSupportedException {
return (ListNode)super.clone();
}
``````

}

``````public ListNode sortList(ListNode head) {
return null;

int count = 0;
count ++;
}

while(queue.size()>1){
Node n1 = queue.poll();
Node n2 = queue.poll();
queue.offer( new Node(merger(n1.listNode, n2.listNode, n1.num, n2.num), n1.num+n2.num));
}
ListNode tail = queue.poll().listNode;
ListNode h = tail;
while(count!=1){
tail = tail.next;
count --;
}
tail.next = null;
return h;
}

// 返回合并后的头结点  num是合并后的链表总长度
public ListNode merger(ListNode first, ListNode second, Integer num1, Integer num2) {

if (biggerThan(first, second) >= 0) {
first = first.next;
num1 --;
}
else {
second = second.next;
num2--;
}
while(num1>0 && num2>0){
if (biggerThan(first, second) > 0){
next.next = first;
first = first.next;
num1 --;
}
else {
next.next = second;
second = second.next;
num2 --;
}
next = next.next;
}

while (num1 > 0) {
next.next = first;
first = first.next;
next = next.next;
num1--;
}
while (num2 > 0){
next.next = second;
second = second.next;
next = next.next;
num2 --;
}

}

int biggerThan(ListNode listNode1, ListNode listNode2){
return listNode1.val - listNode2.val;
}

ListNode create(int []ints){
for (int i:ints){
}
return re.next;
}

public void print(ListNode h) throws CloneNotSupportedException {
ListNode q = h;
while (q!=null){
System.out.println(q.val);
q = q.mclone().next;
}
}

public static void main(String a[]) throws CloneNotSupportedException {
Solution s = new Solution();
ListNode l = s.sortList(s.create(new int[]{}));
s.print(l);
}
``````

}

Runtime Error:
Last executed input: {}

why?

Looks like your connection to LeetCode Discuss was lost, please wait while we try to reconnect.