What will the output of the following code be:
int N=5;
int D=4;
int A=0;
calcValue( N )
System.out.println(N);
static void calcValue( int N ) {
int D;
for (D=0; D<5; D++) {
N++;
}
}
몰르겟지?
What will the output of the following code be:
int N=5;
int D=4;
int A=0;
calcValue( N )
System.out.println(N);
static void calcValue( int N ) {
int D;
for (D=0; D<5; D++) {
N++;
}
}
몰르겟지?
답은8이다
반복문 때매 1 정도 헷갈리긴 하네
왜 5가 아니냐?
문제 자체가 멍청한 거 빼면 답은 5
중간에 ;가 없어서 에러남
어케 5가나옴ㅁ?
아? 아닌가요;;
윽엑으엑 아직 전 자바도, C도 잘 몰라서 모르겠습니다.
사랑해