Print all nodes at distance K from a given node


Please Debug Getting wrong output

I have edited your code a little bit, it is working fine for sample test case,