KIIT Polytechnic logo Students Hub KIIT Polytechnic ସାଇନ୍ ଇନ୍
▲ବୋର୍ଡ ◆ନୋଟ୍ସ ≡ସିଲାବସ୍ ▦ଟାଇମଟେବଲ୍ ?ସନ୍ଦେହ ▶ରିଲ୍ସ 🎮ଶିଖନ୍ତୁ 🐍କୋର୍ସ ◈ସୁଯୋଗ ✍ବ୍ଲଗ୍ ▮ଷ୍ଟୋର୍ ★ଟିମ୍ ⌕ଖୋଜନ୍ତୁ
← Learn to Code — Python for Beginners ମଡ୍ୟୁଲ୍ · Making Decisions

Comparing things

Programs often need to compare two values and get True or False back — this is how they make decisions.

print(5 > 3)
print(5 < 3)
print(5 == 5)
print(5 != 3)

== (double equals) checks if two things are equal. This is different from the single = you used earlier to store a value — mixing these two up is one of the most common beginner mistakes, so it's worth remembering the difference now.