Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using namespace std;
- int main()
- {
- string imie;
- cout<<"Podaj imie: ";
- cin>>imie;
- int dlugosc = imie.length();
- //cout<<dlugosc<<endl;
- cout<<endl;
- if(imie[dlugosc-1]=='a')
- {
- cout<<"Jest to kobieta"<<endl;
- }
- else
- {
- cout<<"Jest to mezczyzna"<<endl;
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement