//SASAOJ-G
#include <stdio.h>
char s[110];
int main() {
int ln=0, flag=1;
scanf("%s", s);
for(; s[ln]; ln++);
for(int i=0; i<(ln+1)/2; i++) {
if((s[i]!=s[ln-i-1])&&((s[i]-32)!=s[ln-i-1])&&(s[i]!=(s[ln-i-1]-32))) {
flag=0;
break;
}
}
if(flag) {
printf("Yes\n");
for(int i=0; i<(ln+1)/2; i++)
printf("%c", s[i]);
}
else {
printf("No\n");
printf("%s", s);
for(int i=ln-1; i>=0; i--)
printf("%c", s[i]);
}
}
To embed this project on your website, copy the following code and paste it into your website's HTML: