#include <stdio.h>
int main() {
char ch;
int n;
scanf("%c %d", &ch, &n);
if ((ch >= 'a' && ch <='z') || (ch >= 'A' && ch <= 'Z')){
if ((ch + n) > 'z') {
printf("%c", ('a' + ((ch + n) - 'z')) - 1);
}
else if ((ch + n) > 'Z') {
printf("%c", ('A' + ((ch + n) - 'Z')) - 1);
}
else {
printf("%c", (ch + n));
}
} //소문자인 경우
else {
printf("%c", ch);
}
return 0;
}
To embed this project on your website, copy the following code and paste it into your website's HTML: