Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- #include <string.h>
- int main()
- {
- char A[100010];
- scanf("%s", A);
- int n = strlen(A);
- int ok = 1;
- for (int i = 0; i < n; ++i) {
- if (A[i] != A[n-i-1]) {
- ok = 0;
- break;
- }
- }
- printf("%s\n", ok ? "YES" : "NO");
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement