AlbertMourato

Untitled

Nov 24th, 2014
179
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.39 KB | None | 0 0
  1. #include <bits/stdc++.h>
  2. using namespace std;
  3. int main(){
  4.     string entrada;
  5.     int k;
  6.     bool go = true;
  7.     cin>>entrada;
  8.     while(go){
  9.         k = entrada.size()-1;
  10.         while(k>-1){
  11.             cout<<entrada[k];
  12.             k--;
  13.         }
  14.         if(cin>>entrada){
  15.             go = true;
  16.             cout<<" ";
  17.         }else{
  18.             go = false;
  19.         }
  20.     }
  21.  
  22. }
Advertisement
Add Comment
Please, Sign In to add comment