↻
72번부터 같은 회차 100문항을 이어서 풉니다.
72/ 100문항 자료 불러오는 중
정처LAB 자체 제작 · 내용 검수 완료프로그래밍 언어 활용 · C 저장 클래스 · 정처LAB 정보처리기사 필기 자체 제작 2회 · 72번
다음 C 프로그램의 출력 결과는?
#include <stdio.h>
int accumulate(int x) {
static int total = 1;
total += x;
return total;
}
int main(void) {
int a = accumulate(2);
int b = accumulate(a);
int c = accumulate(-2);
printf("%d %d", b, c);
return 0;
}