+ 1
Can somebody describe me this programm? I don't understand what the output is and how this programm works. Thanks.
int[] a={8, 3, 2}; for (int i=1; i <2; i++) { a[0] *= a[0] } System.out.print(a[0]); Tanks for help! German answers are better than eglish. But I understand both.
2 Antworten
+ 5
a0 is the first value in the index which is 8. I=1 and must be less than 2, so the for loop will run once. so 8*8 is 64.
+ 1
oh nice thx