Comparing among data type | Sololearn: Learn to code for FREE!
Novo curso! Todo programador deveria aprender IA generativa!
Experimente uma aula grƔtis
+ 1

Comparing among data type

Hi,I were playing a challenge and I have found a question include comparing between two lists like this [1,2,3,4]> [1,2,3] The rest was False šŸ¤  That's make me think about more comparing possiblities like comparing between a string and another...etc can someone explain how can I find the result and thanks ā™„ļø

24th Aug 2022, 5:58 PM
Moha Riad
Moha Riad - avatar
1 Resposta
+ 3
You can normally compare built-in types. It depends on the implementation of methods __eq__and __gt__ how comparison is done.
24th Aug 2022, 6:24 PM
Oma Falk
Oma Falk - avatar