String Palindrome
String Palindrome PROBLEM STATEMENT : A string S is passed as input to the program. The program must print "yes" if the string S is a palindrome and must print "no" if the string is NOT a palindrome. Boundary Condition(s): 1<=length(S)<=10000 Input Format: The first line will contain the value of the string S. Output Format: The first line in the output should contain "yes" or "no" based on the input. Example Input/Output 1: Input: ( ) malayalam Output: yes Example Input/Output 2: Input: ( ) manager Output: no SOLUTION : C (Programming Language) Copy Code #include<stdio.h> #include<stdlib.h> int main() { char s[1001],r[1001],t; int l,i=0; scanf("%s%n",s,&l); strcpy(r,s); l-=1; while(i<l) { t=s[i]; s[i]=s[l]; s[l]=t; i++; l--; } if(strcmp(s,r)==0) printf("yes"); else printf("no"); } ...