0

What is the Difference between x=y and x==y

????????

16th Aug 2018, 12:48 PM
Jordyn Nicholas
Jordyn Nicholas - avatar
3 Answers
+ 6
= is the assignment operator. x = y means that the value of y is being assigned to x. == is the comparison operator. x == y checks whether x is equal to y or not.
16th Aug 2018, 1:38 PM
Harsh
Harsh - avatar
+ 1
one changes x's value to y and second one returns true or false depending on is x equal to y or not
16th Aug 2018, 12:51 PM
null
null - avatar
0
== a signal for show a equal value. Example : x =5 y = 5 In this case,x is equal to y. x == y However,if x = 5 and y = 6 The result will be x = 6
16th Aug 2018, 1:00 PM
Lucas
Lucas - avatar