+ 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?
14 Respostas
0
So, those are short forms:
x += 3
is the same as
x = x + 3;
With
-=
*=
/=
it's the same, just change the operator:)
+ 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
+ 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.
+ 1
wow... that is the best answer I got. I lost lots of challenges because of it. Thanks
+ 1
No Problem:) I'm here to help
+ 1
If you have another question someday, just put @Jonas Schröter into your post, I'll find it then.
+ 1
Ok bro thanks. I followed you as well
+ 1
Nice:)
+ 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.
0
any practical work please?
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
0
Someone please tell me how much java code knowledge is enough for being a professional android developer..??
0
Just start out making your own small apps and practice:)
0
Thank u jonas andb haskar.