You are viewing a single comment's thread. Return to all comments →
Iterative code in Python
def reversePrint(head): x = head l = [] if head is not None: while(x is not None): l.append(x.data) x = x.next print('\n'.join(map(str, l[::-1])))
Seems like cookies are disabled on this browser, please enable them to open this website
Print in Reverse
You are viewing a single comment's thread. Return to all comments →
Iterative code in Python