@@ -0,0 +1,370 @@
+public class Solution %7B%0A    public void connect(TreeLinkNode root) %7B%0A        if(root == null) %7B%0A            return;%0A        %7D%0A        if(root.left!=null) %7B%0A            root.left.next = root.right;%0A            if(root.next!=null) %7B%0A                root.right.next = root.next.left;%0A            %7D%0A        %7D%0A        connect(root.left);%0A        connect(root.right);%0A    %7D%0A%7D%0A

Create PopulatingNextRightPointersinEachNode.java