Array increment operator
Posted
by Stardust
on Stack Overflow
See other posts from Stack Overflow
or by Stardust
Published on 2010-03-14T19:59:25Z
Indexed on
2010/03/14
20:05 UTC
Read the original article
Hit count: 209
Could any one please tell me the meaning of "++" with array in the following code in Java:
int [ ] arr = new int[ 4 ];
for(int i = 0; i < arr.length; i++){
arr[ i ] = i + 1;
System.out.println(arr[ i ]++);
}
what is arr[ i ]++
meaning in above code, and why we can't do like:
arr[ i ]++ = i + 1;
© Stack Overflow or respective owner