==: This checks whether two strings are equal
!=: This checks if two strings are not equal
<: This checks if the string on its left is smaller than that on its right
<=: This checks if the string on its left is smaller than or equal to that on its right
>: This checks if the string on its left is greater than that on its right
>=: This checks if the string on its left is greater than or equal to that on its right
text1 = 'apple'
text2 = 'apple'
text1 == text2
#RETURNS true
# Comparison is done through "lexicographic" order of letters
# Change the variable 'word' then run and see the results
# Remember a capital letter comes before a simple letter
word = 'banana'
if word == 'banana':
print('All right, bananas.')
if word < 'banana':
print('Your word', word, 'comes before banana')
elif word > 'banana':
print('Your word', word, 'comes after banana')
else:
print('All right, bananas.')