Write a python program that takes the input of name from the user and stores every character of name in a list and display the fifth character of the name.
Answers
Answered by
0
Answer:
naive approach of this will be to iterate for spaces and print the next letter after every space except the last space. At last space we have to take all the characters after the last space in a simple approach.
Using Python in inbuilt functions we can split the words into a list, then traverse till the second last word and print the first character in capitals using upper() function in python and then add the last word using title() function in Python which automatically converts the first alphabet to capital.
Similar questions