Function to print the level order of given binary tree . Direction of printing level order traversal of binary tree changes after every two levels
function modifiedLevelOrder ( root ) { if ( root == null ) return ; let dir = LEFT ; let temp ; let Q = [ ] ; let S = [ ] ; S . push ( root ) ;