public static void printSpiralOder(BinaryTreeNode node)
    {
        //S1 for processing odd levels i.e from right to left
        Stack<BinaryTreeNode> s1 = new Stack<>();
        //S2 for processing even levels i.e left to right
        Stack<BinaryTreeNode> s2 = new Stack<>();
        if (node != null) {
            s1.push(node);
            //root is added
        }


        while (!s1.isEmpty() || !s2.isEmpty()) {
            while (!s1.isEmpty()) {
                //in the first traversal, root is removed
                BinaryTreeNode n = s1.pop();
                System.out.print(n.getValue() + " ");
                //add all children from right to left
                //when you pop.. the order will be left to right
                if (n.getRight() != null) {
                    s2.push(n.getRight());
                }
                if (n.getLeft() != null) {
                    s2.push(n.getLeft());
                }
            }

            while (!s2.isEmpty()) {
                BinaryTreeNode n = s2.pop();
                System.out.print(n.getValue() + " ");
                //add all children from left to right
                //when you pop.. the order will be right to left
                if (n.getLeft() != null) {
                    s1.push(n.getLeft());
                }
                if (n.getRight() != null) {
                    s1.push(n.getRight());
                }

            }
        }
    }