+ 1

Can someone explain the uses or meaning of == operator?

2nd Oct 2016, 1:34 PM
Declan
Declan - avatar
4 Answers
+ 2
I am also a beginner, but as far as I'm concerned, it is used to know if two objects are equal or not. Depending on the case, the output would be the logical answers: True or False.
3rd Oct 2016, 1:30 PM
Juan O. A.
Juan O. A. - avatar
+ 2
== is comparator, = assignment
4th Oct 2016, 11:30 AM
Redstone Tehnik
Redstone Tehnik - avatar
+ 2
own yeah a comparator now i get it thanks dude
4th Oct 2016, 4:37 PM
Declan
Declan - avatar
+ 1
Suppose Assignment Operator x = 1 print x Ans : 1 Comparison Operator x = 2 y = 3 if x == y print "not comparison operation" else print "comparison operation" Ans : In this case x and y are not same so it will give else print statement x = 3 y = 3 if x == y print 1 else print 0 Ans : in this case x and y are same so it will give if condition print statement
26th Oct 2016, 9:10 PM
Ugra Narasimha
Ugra Narasimha - avatar