+ 7

+= operator heeeeellppppp

Can someone elaborate the += thing to me? Thank you ❤️

3rd Jan 2021, 3:52 PM
Kakai
Kakai - avatar
7 ответов
+ 4
x += 7 is the same as if we write x = x + 7 It is just a shorter version.
3rd Jan 2021, 4:05 PM
Lisa
Lisa - avatar
+ 4
Abbakar_ah💻💻 I think you are talking about x++
5th Jan 2021, 10:55 AM
Sonic
Sonic - avatar
+ 3
Simply put, x += y acts like x = x + y. But isn't this explained in the lesson? try to review operators chapter please, might help 👍
3rd Jan 2021, 4:05 PM
Ipang
+ 3
Let's take an example, X+=y Which means, X=X+y Hope it will be helpful to you 🙂
3rd Jan 2021, 4:27 PM
KRITI
KRITI - avatar
+ 1
It just means use my current value and add this value to it
3rd Jan 2021, 4:58 PM
D_Stark
D_Stark - avatar
+ 1
Thank you guys ❤️
3rd Jan 2021, 10:03 PM
Kakai
Kakai - avatar
+ 1
It's just a simpe way of writing x = x + 1 in any programming language
4th Jan 2021, 7:44 PM
Abbakar_ah!!!
Abbakar_ah!!! - avatar