Write a program to reverse a string using a stack data structure.
HardProblem Statement
Write a program to reverse a string using a stack data structure.
Sample Input
std::string str = "Hello";
Sample Output
Reversed string: olleH
Limits
Time: 2s · Memory: 256 MB