#include <iostream>
#include <string>
using namespace std;
int main()
{
string x;
getline(cin,x);
string y = "";
for(int i=0;i<x.length();i++){
if(x[i] != ' ') y=y+x[i];
else{
y[0] = y[0]-32;
cout << y <<"\n";
y="";
}
}
y[0]=y[0]-32;
cout << y;
return 0;
}