upup

You are given a string S. S consists of several words separated by one or more spaces. Word consists of Latin letters as well as other symbols (but not spaces).
In each word which starts from lowercase Latin letter replace starting letter with uppercase Latin letter.

Input
The only line contains S

Output
Output one line with modified string S.

Constraints
1 ≤ length of S ≤ 30 000

SAMPLE INPUT
Wish you were here

SAMPLE OUTPUT
Wish You Were Here

Difficulty: EASY

Starter code:

Solutions:
s = input()
y = []
for x in s.split(' '):
	if x and x[0].isalpha() and x[0].islower():
		x = x[0].upper() + x[1:]
	y.append(x)
print(' '.join(y))


s = list(input())
for i in range(len(s)):
	c = ord(s[i])
	if (c > 96 and c < 123 and (s[i - 1] == ' ' or i == 0)):
		s[i] = chr(c - 32)
print((''.join(s)))


'''
# Read input from stdin and provide input before running code

name = raw_input('What is your name?\n')
print 'Hi, %s.' % name
'''

S = input()
T = []
PrevIsSpace = True

for i,l in enumerate(S):
	if PrevIsSpace and l>='a' and l<='z':
		l = chr(ord(l)-ord('a') + ord('A'))
	PrevIsSpace = (l == ' ')
	T.append(l)


print("".join(T))


s = input()
ls = s.split(' ')
vals = []
for p in ls:

	if len(p) > 0 and p[0].isalpha():
		lets = p[0].upper()
		if len(p) > 1:
			vals.append(lets + p[1:])
		else:
			vals.append(lets)
	else:
		vals.append(p)
print(' '.join(vals))
		


x=input()
x=list(x)
x[0]=x[0].upper()
for i in range(1,len(x)):
	if x[i].isalpha() and x[i-1]==" ":
		x[i]=x[i].upper()
x=''.join(x)
print(x)


ss=input()
li=ss.split(" ")
s1=""
for i in range(0,len(li)):
	if(len(li[i])>1):
		s1+=li[i][0].upper()+li[i][1:]+" "
	else:
		s1+=li[i].upper()+" "
print(s1)
s1=""


S = input()
if len(S) in range(1, 30001):
	newString = ''
	flag = True
	
	for char in S:
		if char == ' ':
			flag = True
			newString += char
		else:
			newString += char.upper() if flag else char
			flag = False

	print(newString)


'''
# Read input from stdin and provide input before running code

name = raw_input('What is your name?\n')
print 'Hi, %s.' % name
'''
import sys

for line in sys.stdin:
	ll = list(line)
	up = True
	for i in range(0, len(ll)):
		if ll[i] != ' ' and up:
			ll[i] = ll[i].upper()
			up = False
		
		if ll[i] == ' ':
			up = True
		
	sys.stdout.write(''.join(ll))
			
		


'''
# Read input from stdin and provide input before running code

name = raw_input('What is your name?\n')
print 'Hi, %s.' % name
'''
#print 'Hello World!'
s=input()
l=[]
if s[0]!=" ":
	if ord(s[0])>=92:
		l.append(chr(ord(s[0])-32))
	else:
		l.append(s[0])
for i in range(1,len(s)):
	if s[i]!=" " and s[i-1]==" ":
		if ord(s[i])>=92:
			l.append(chr(ord(s[i])-32))
		else:
			l.append(s[i])
	else:
		l.append(s[i])
print("".join(l))


s=input()
s1=""
if 96<ord(s[0])<123:
	s1=s1+chr(ord(s[0])-32)
else:
	s1=s1+s[0] 
for i in range(1,len(s)):
	if s[i-1]==" " and 96<ord(s[i])<123:
			s1=s1+chr(ord(s[i])-32)
	else:
			s1=s1+s[i]
print(s1)   
	


'''
# Read input from stdin and provide input before running code

name = raw_input('What is your name?\n')
print 'Hi, %s.' % name
'''
inp = input()
# print(len(inp))
listStr = list(inp)
start = 0
end = start
while(end < len(listStr)):
	while(start < len(listStr) and listStr[start] == ' '):
		start = start + 1

	end = start + 1
	while(end < len(listStr) and listStr[end] != ' '):
		end = end + 1

	if(start < len(listStr)):
		# print str(start) + " has character " + listStr[start]
		listStr[start] = listStr[start].upper()		
		# print str(start) + " has character " + listStr[start]

	start = end

inp = "".join(listStr)
# print(len(inp))
print(inp)

	


import re
s = input().strip()
ans = s[0].upper()
spc = 0
for x in s[1:]:
	if x == " ":
		spc += 1
	else:
		if spc > 0:
			ans += " "*spc + x.upper()
			spc = 0
		else:
			ans += x
print(ans)               


	


'''
# Read input from stdin and provide input before running code

name = raw_input('What is your name?\n')
print 'Hi, %s.' % name
'''
ans = ''
s = input()
ls = 1
ans = ans+s[0].upper()
while ls < len(s):
	if s[ls] == ' ' and s[ls+1] != ' ':
		or_d = ord(s[ls+1])
		# if or_d >= 97 and or_d <= 122:
		ans = ans + ' '+s[ls+1].upper()
		# else:
			# ans = ans+' '+s[ls+1]
		ls = ls+2
	else:
		ans = ans + s[ls]
		ls = ls + 1
print(ans)


'''
# Read input from stdin and provide input before running code

name = raw_input('What is your name?\n')
print 'Hi, %s.' % name
'''
ans = ''
s = input()
ls = 1
# len(s)
ans = ans+s[0].upper()
while ls < len(s):
	if s[ls] == ' ' and s[ls+1] != ' ':
		or_d = ord(s[ls+1])
		if or_d >= 97 and or_d <= 122:
			ans = ans + ' '+s[ls+1].upper()
		else:
			ans = ans+' '+s[ls+1]
		ls = ls+2
	else:
		ans = ans + s[ls]
		ls = ls + 1
print(ans)


'''
# Read input from stdin and provide input before running code

name = raw_input('What is your name?\n')
print 'Hi, %s.' % name
'''
x=input()
f=-1
l = len(x)
z=""
for i in range(0,l):
	if f==-1 and x[i]!=' ':
		z = z+(x[i]+"").capitalize()
		f=0
	elif x[i]==' ':
		z = z+" "
		f=-1
	else:
		z=z+x[i]
print(z)
	


'''
# Read input from stdin and provide input before running code

name = raw_input('What is your name?\n')
print 'Hi, %s.' % name
'''
#print 'Hello World!'
import re

inputStr = input()
inputStrArr = re.split(r'(\s+)', inputStr)

for j, elem in enumerate(inputStrArr):
	if elem:
		elemArr = list(elem)
		elemArr[0] = elemArr[0].upper()
		#print elemArr
		inputStrArr[j] = "".join(elemArr)

print("".join(inputStrArr))


t = input()
t = list(t)
for i in range(len(t)-1):
	if i == 0:
		u = t[i].upper()
		t[i]=u
	if(t[i]==' ' or t[i]=='\n'):
		if(t[i+1].isalpha()):
			p = t[i+1].upper()
			t[i+1] = p
print("".join(t))
 


string = input()

start = 0
upperLimit = len(string) - 1

modifiedString = ""

while(start <= upperLimit):
	ch = string[start]

	if(start == 0 and ch.isalpha()):
		modifiedString += ch.upper()
	elif(start == 0 and ch == ' '):
		modifiedString += ch
	elif(string[start - 1] == ' '):
		modifiedString += ch.upper()
	else:
		modifiedString += ch
	start += 1
print(modifiedString)	


'''
# Read input from stdin and provide input before running code

name = raw_input('What is your name?\n')
print 'Hi, %s.' % name
'''
import string
s=input()
#s_array=s.split(" ")
s1=[]
convert = -1
#wish you were here
for i in range(0,len(s)):
#	for j in range(0,len(s_array[i])):
	if i == 0 and s[i].islower() == True:
		s1.append(s[i].upper())
	elif s[i]!= ' ' and convert == 1:
		s1.append(s[i].upper())
		convert = -1
	elif s[i] == ' ':
		convert=1
		s1.append(s[i])
	else:
		s1.append(s[i])
	#print s[i]
		
print(''.join(s1))





	#print s_array[i][0]
	#print s_array[i][0].islower()
	#print "Upper : ",s_array[i][0].upper()
	#if s_array[i][0].islower() == True:
		#s_array[i][0]=s_array[i][0].toupper()
		#print s_array[i][0]
		#print "Upper : ",s_array[i][0].upper
		#x=s_array[i][0].upper()
		#s_array[i][0] = x
		#print x
		#s_array[i][0]='A'
		#print s_array[i][0].toupper()
		#s_array[i][0]=s_array[i][0].upper()
		#print s_array[i][0]
#print s_array
#print string.join(s_array)


s=input()
t=len(s)
ans=''
word=True
for i in range(t):
	if word and ord('a')<=ord(s[i])<=ord('z'):
		ans+=(s[i].upper())
		word=False
	else:
		ans+=s[i]
		if s[i]==' ':
			word=True
		else:
			word=False	
print(ans)				


import re
string = input()
bSpace = False
modString = ''

for x in range(len(string)):
	char= string[x]
	if x == 0 and x != " ":
		modString += char.upper()
		continue		
	if char == " ":
		bSpace = True
		modString += char
		continue
	if bSpace:
		modString += char.upper()
		bSpace = False
		continue
	modString += char

print(modString)