Convert string to camel case Python

In this Python string tutorial, you will learn how to convert a string to a camel case in Python.

# Create a string
S = "Ai hints"

# Convert string into camel case
C = S.title().replace(" ", "")

# Print camel case
print(C)

# Display the type of C
print(type(C))

Output:

AiHints
<class 'str'>

Free learning resources: AiHintsCodeAllow

Leave a Comment

Your email address will not be published.