1 / \ 2 3 / / \ 4 7 8
root = Node ( 1 ) NEW_LINE root . left = Node ( 2 ) NEW_LINE root . right = Node ( 3 ) NEW_LINE root . left . left = Node ( 4 ) NEW_LINE root . right . right = Node ( 8 ) NEW_LINE root . right . left = Node ( 7 ) NEW_LINE k = 2 NEW_LINE print " Before ▁ swap ▁ node ▁ : " NEW_LINE inorder ( root ) NEW_LINE swapEveryKLevel ( root , k ) NEW_LINE print   " NEW_LINE After swap Node :   " NEW_LINE inorder ( root ) NEW_LINE