In this program, we will take a string as input and convert half the string to uppercase.
Steps to solve the program
- Take a string as input.
- Convert the half of the string upper() and Indexing.
- Print the output.
#Input string
str1 = "banana"
#Printing output
print(str1[:3]+str1[3:].upper())
Output :
banANA