Lesson 7 of 34
तुलना: True या False
6 min 20 XP
जब आप दो मानों की तुलना करते हैं, Python जवाब True या False में देता है। इन्हें Booleans कहते हैं।
Example: edit me and press Run
Output Loading Python (first time takes a few seconds)
Press Run to see the result here.= मान रखता है (assign)। == पूछता है “क्या ये बराबर हैं?” (compare)। इन्हें आपस में मत मिलाइए!
आप strings की तुलना भी कर सकते हैं, पर बड़े-छोटे अक्षर मायने रखते हैं: "Chennai" और "chennai" बराबर नहीं हैं।
Example: edit me and press Run
Output Loading Python (first time takes a few seconds)
Press Run to see the result here.