convert half the string to uppercase.

In this program, we will take a string as input and convert half the string to uppercase.

Steps to solve the program
  1. Take a string as input.
  2. Convert the half of the string upper() and Indexing.
  3. Print the output.
				
					#Input string
str1 = "banana"

#Printing output
print(str1[:3]+str1[3:].upper())
				
			

Output :

				
					banANA
				
			

insert space before every capital letter appears in a given word

split and join a string using “-“

Leave a Comment