#include<bits/stdc++.h>
using namespace std;
int main(){
int j=1;
char s[114515];
cin.getline(s,114514);
s[strlen(s)]=' ';
s[strlen(s)+1]='\0';
for(int i=0;i<(strlen(s));i++){
if(s[i]!=' '&&j%2==1){s[i]=toupper(s[i]);j++;}
else if(s[i]!=' '&&j%2==0&&!(s[i]>='a')&&!(s[i]<='z')){j++;s[i]=char(int(s[1])+36);}
else j=1;
}
cout<<s;
return 0;
}