fork download
  1. #include <iostream>
  2. #include <string>
  3. using namespace std;
  4. int main() {
  5. string s;
  6. cin>>s;
  7. bool x=true;
  8. for( int i=0; i < s.length(); i++)
  9. {if (s[i]!=s[s.length()-i]){x=false;}}
  10. if(x){
  11. cout<<"yes";
  12. }
  13. else {cout<<"no";}
  14. return 0;
  15. }
Success #stdin #stdout 0s 16048KB
stdin
dssd
stdout
no