Skip to content

Instantly share code, notes, and snippets.

@IndhumathyChelliah
Last active June 29, 2020 05:03
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save IndhumathyChelliah/a1e2f7deb71a7bffaaa16ae3ccfe10ca to your computer and use it in GitHub Desktop.
Save IndhumathyChelliah/a1e2f7deb71a7bffaaa16ae3ccfe10ca to your computer and use it in GitHub Desktop.
s1="Hello World"
print (s1.istitle())#Output:True
print (s1.isupper())#Output:False
print (s1.islower())#Output:False
s2="Hello world"
print (s2.istitle())#Output:False
print (s2.isupper())#Output:False
print (s2.islower())#Output:False
s3="hello 123"
print (s3.istitle())#Output:False
print (s3.isupper())#Output:False
print (s3.islower())#Output:True
s4="HELLO 123"
print (s4.istitle())#Output:False
print (s4.isupper())#Output:True
print (s4.islower())#Output:False
s5="hello$"
print (s5.istitle())#Output:False
print (s5.isupper())#Output:False
print (s5.islower())#Output:True
s6="HELLO$"
print (s6.istitle())#Output:False
print (s6.isupper())#Output:True
print (s6.islower())#Output:False
s7=''
print (s7.istitle())#Output:False
print (s7.isupper())#Output:False
print (s7.islower())#Output:False
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment