You are asked to ensure that the first and last names of people begin with a capital letter in their passports. For example, alison heck should be capitalised correctly as Alison Heck.
i/p : alison heck
o/p: Alison Heck
Note: in a word only the first character is capitalized. Example 12abc when capitalized remains 12abc.
def solve(s): return ' '.join(i.capitalize() for i in s.split(' '))
import string def solve(s): return string.capwords(s,' ')