Reply To: comparing digits and letters 1 >’a’ outputs an error

Python Land Forums The Python Tutorial comparing digits and letters 1 >’a’ outputs an error Reply To: comparing digits and letters 1 >’a’ outputs an error

#1663
Lu
Participant

Thanks,

If I follow this correctly then in the case ‘1’<‘a’ the 1 is not an integer type but the unicode character ‘1’

When looking at the character map, ‘!’ would be the smallest of all unicode characters and ‘ﻼ’ will be the largest. Python evaluated it to True

>>> '!'<'ﻼ'
True