최신 C++ Institute Certification CLA-11-03 무료샘플문제:
1. What happens if you try to compile and run this program?
#include <stdio.h>
int main (int argc, char *argv[]) {
int i = 7 || 0 ;
printf("%d", !! i);
return 0;
}
Choose the right answer:
A) The program outputs 7
B) The program outputs 0
C) Compilation fails
D) The program outputs -1
E) The program outputs 1
2. What happens if you try to compile and run this program?
#include <stdio.h>
#include <stdlib.h>
int main (int argc, char *argv[]) {
double x = 1234567890.0;
printf ("%f",x);
return 0;
}
Choose the most precise answer:
A) Compilation fails
B) The program outputs 1234567890.0
C) The program outputs 1234567900.0
D) The program outputs a value greater than 1234500000.0 and less than 1234600000.0
E) Execution fails
3. What happens if you try to compile and run this program?
#include <stdio.h>
#include <string.h>
int main (int argc, char *argv[]) {
int a = 0, b = 1, c;
c = a++ && b++;
printf("%d",b);
return 0;
}
Choose the right answer:
A) The program outputs 0
B) Compilation fails
C) The program outputs 3
D) The program outputs 2
E) The program outputs 1
4. What happens if you try to compile and run this program?
#include <stdio.h>
int main (int argc, char *argv[]) {
int i = 'A' - 'B';
int j = 'b' - 'a';
printf("%d",i / j);
return 0;
}
Choose the right answer:
A) The program outputs 0
B) Compilation fails
C) Execution fails
D) The program outputs -1
E) The program outputs 1
질문과 대답:
질문 # 1 정답: E | 질문 # 2 정답: B | 질문 # 3 정답: E | 질문 # 4 정답: D |