• We’re currently investigating an issue related to the forum theme and styling that is impacting page layout and visual formatting. The problem has been identified, and we are actively working on a resolution. There is no impact to user data or functionality, this is strictly a front-end display issue. We’ll post an update once the fix has been deployed. Thanks for your patience while we get this sorted.

Quick question about java....

Ns1

No Lifer
I got a question about the increment operator in java

a=1
A++ means that A is now equal to 2, but when does it increment?

ex)

i = 1;
system.out.print(i++);


assuming my syntax is correct

would that print 1, then increase i to 2, or increase i to 2 then print it?

i think i++ would write it first, then increment it, and ++i would increment it, then write it

correct? yes no maybe so????
 
That is correct, and it's the same in C++. I hate Java though. I'm taking a class in it and I just plain don't like it. TONS of work to do simple stuff.
 


<< That is correct, and it's the same in C++. I hate Java though. I'm taking a class in it and I just plain don't like it. TONS of work to do simple stuff. >>



You MUST be kidding?? How much simpler could it possibly be? Java abstracted a great majority of the complexity that you would otherwise incur in C++ by way of their class library.
 
Back
Top