Advertisement
Guest User

Untitled

a guest
Oct 12th, 2017
70
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.48 KB | None | 0 0
  1. #include <iostream>
  2. #include <string>
  3.  
  4. using namespace std;
  5.  
  6. int main()
  7. {
  8.     string imie;
  9.  
  10.     cout<<"podaj imie"<<endl;
  11.     cin>>imie;
  12.  
  13.     int dlugosc=imie.length();
  14.  
  15.     if (imie[dlugosc-1]=='a')
  16.     cout<<"wydaje mi sie ze jestes kobieta";
  17.     else cout<<"wydaje mi sie ze jestes facetem";
  18.  
  19. {
  20.     int dlugosc = imie.length();
  21.  
  22.     for (int i=dlugosc-1; i>=0; i--)
  23.     {
  24.     cout<<"twoje imie od tylu to:"<<;
  25.     cout<<imie[i];
  26.     }
  27.  
  28.  
  29.  
  30.  
  31.     return 0;
  32. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement