Computer Science, asked by mitapal1087, 6 hours ago

Give the output of the following statements
>>> str='Hello World'
>>>str.istiltle()​

Answers

Answered by anindyaadhikari13
1

Corrected co‎de:

str='Hello World'

print(str.istitle())

Output:

  • True

Explanation:

  • In Python, the istitle() method checks whether a sentence is in title case or not.
  • In other words, it checks whether first letter of all words present in the string is in uppercase or not.
  • Here, we can see that 'Hello' as well as 'World' both starts with uppercase letter. So, the method returns True.
Similar questions