#include <iostream>
#include <stack>
using namespace std;
string reverseString(string str){
stack<char>s;
string rstr;
for(int i=0;i< str.size();i++){
s.push(str[i]);
}
while(!s.empty()){
char temp=s.top();
rstr=rstr+temp;
s.pop();
}
return rstr;
}
int main() {
string str="hello World";
cout<< " Original String:-" <<str<<endl;
cout<< " Reverse String:- " <<reverseString(str)<<endl;
return 0;
}