PEC-CSS/Open-Source

Reverse a Stack

Closed this issue · 3 comments

Given a stack, with a program to recursively reverse the stack without using any new stack.

Your Task:

You are given a stack, your task is to design a function ReverseStack which takes the stack as input and reverses the stack.
If the original stack were: 1->2->3->4
After ReverseStack(): 4->3->2->1

Time complexity: O(n ^ 2).
Space complexity: O(n).

I would like to work on this repo under hackocberfest lebels
plz assign me.
thank you

I would like to work on this repo under hackocberfest lebels plz assign me. thank you

@Prashant0kgp Assigned

plz, review my code(reverse a stack mentioned in #297.)
thank you,