Trusted answers to developer questions
Trusted Answers to Developer Questions

Related Tags

What is the istitle() function in Python?

GaneshPrasad

Grokking Modern System Design Interview for Engineers & Managers

Ace your System Design Interview and take your career to the next level. Learn to handle the design of applications like Netflix, Quora, Facebook, Uber, and many more in a 45-min interview. Learn the RESHADED framework for architecting web-scale applications by determining requirements, constraints, and assumptions before diving into a step-by-step design process.

Python has many in-built functions. The istitle() is one of these built-in functions that return True.

If the input string is a title case string and there is at least one character, the function returns False.

For example, uppercase characters can only follow uncased characters, and lower case characters can only follow cased characters.

Syntax

The syntax for istitle() is:

str.istitle()

There are no parameters for this function.

Code

x = "The Tea Ceremony"
print(str.istitle(x))
y = "the tea ceremony"
print(str.istitle(y))

RELATED TAGS

Grokking Modern System Design Interview for Engineers & Managers

Ace your System Design Interview and take your career to the next level. Learn to handle the design of applications like Netflix, Quora, Facebook, Uber, and many more in a 45-min interview. Learn the RESHADED framework for architecting web-scale applications by determining requirements, constraints, and assumptions before diving into a step-by-step design process.

Keep Exploring