// value -1 means not to create node/child
        public static TreeNode <int> InitializeBinaryTree()
        {
            var            queue = new GenericLLQueue <TreeNode <int> >();
            TreeNode <int> root  = null;
            int            val   = 0;

            Console.Write("Enter value for Root Node : ");
            val = int.Parse(Console.ReadLine());

            root       = new TreeNode <int>();
            root.Value = val;
            root.Left  = null;
            root.Right = null;
            queue.Enqueue(root);

            while (!queue.IsEmpty())
            {
                var p = queue.Dequeue();

                Console.Write("Enter value for Left Child of Node ({0}) : ", p.Value);
                val = int.Parse(Console.ReadLine());
                if (val != -1)
                {
                    var leftChild = new TreeNode <int>();
                    leftChild.Value = val;
                    leftChild.Left  = null;
                    leftChild.Right = null;
                    p.Left          = leftChild;
                    queue.Enqueue(leftChild);
                }

                Console.Write("Enter value for Right Child of Node ({0}) : ", p.Value);
                val = int.Parse(Console.ReadLine());
                if (val != -1)
                {
                    var rightChild = new TreeNode <int>();
                    rightChild.Value = val;
                    rightChild.Left  = null;
                    rightChild.Right = null;
                    p.Right          = rightChild;
                    queue.Enqueue(rightChild);
                }
            }

            return(root);
        }
        private static void LevelTraversal(TreeNode <int> root)
        {
            var queue = new GenericLLQueue <TreeNode <int> >();
            var node  = root;

            Console.Write("({0}), ", node.Value);
            queue.Enqueue(node);

            while (!queue.IsEmpty())
            {
                node = queue.Dequeue();
                if (node.Left != null)
                {
                    Console.Write("({0}), ", node.Left.Value);
                    queue.Enqueue(node.Left);
                }

                if (node.Right != null)
                {
                    Console.Write("({0}), ", node.Right.Value);
                    queue.Enqueue(node.Right);
                }
            }
        }