Can anyone tell me about Assignment operators? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 1

Can anyone tell me about Assignment operators?

I am a beginner want to learn java more and more to become a professional programmer. But I didn't get Assignment operators yet. can any body explain or give send me link?

29th May 2018, 3:50 PM
Bashir Ahmad
Bashir Ahmad - avatar
14 Answers
0
So, those are short forms: x += 3 is the same as x = x + 3; With -= *= /= it's the same, just change the operator:)
29th May 2018, 7:58 PM
Jonas Schröter
Jonas Schröter - avatar
+ 1
Look buddy assignment operator is operator used to assign values to varibles. It plays important as every bit of is just incomplete without assignment operators. You simply assign the values on RIGHT-HAND side to the variable present on LEFT-HAND side.Which the varible will carry if not changed untill the code is executed completely
29th May 2018, 4:08 PM
Bhaskar Tak
+ 1
int x; x = 9; = is the assignment operator. The value on the right side is assigned to the variable on the left. x is the variable, 9 the value int y = x; Same here. y is the variable, but now it's important to unterstand that not x is assigned to y but it's value, means 9.
29th May 2018, 7:20 PM
Jonas Schröter
Jonas Schröter - avatar
+ 1
wow... that is the best answer I got. I lost lots of challenges because of it. Thanks
29th May 2018, 8:00 PM
Bashir Ahmad
Bashir Ahmad - avatar
+ 1
No Problem:) I'm here to help
29th May 2018, 8:00 PM
Jonas Schröter
Jonas Schröter - avatar
+ 1
If you have another question someday, just put @Jonas Schröter into your post, I'll find it then.
29th May 2018, 8:02 PM
Jonas Schröter
Jonas Schröter - avatar
+ 1
Ok bro thanks. I followed you as well
29th May 2018, 8:04 PM
Bashir Ahmad
Bashir Ahmad - avatar
+ 1
Nice:)
29th May 2018, 8:04 PM
Jonas Schröter
Jonas Schröter - avatar
+ 1
if you know already the basics ( classes, objects, inheritance, interfaces ) I think you're ok to start. First of all build small apps and practice.
30th May 2018, 10:46 AM
Bhaskar Tak
0
any practical work please?
29th May 2018, 5:06 PM
Bashir Ahmad
Bashir Ahmad - avatar
0
Jonas Schröter thanks for your answer I just don't know the assignment operators a += b a -= b etc... can you please teach me
29th May 2018, 7:56 PM
Bashir Ahmad
Bashir Ahmad - avatar
0
Someone please tell me how much java code knowledge is enough for being a professional android developer..??
30th May 2018, 10:42 AM
Sandeep Singh
Sandeep Singh - avatar
0
Just start out making your own small apps and practice:)
30th May 2018, 10:43 AM
Jonas Schröter
Jonas Schröter - avatar
0
Thank u jonas andb haskar.
31st May 2018, 8:58 PM
Sandeep Singh
Sandeep Singh - avatar