C++ Institute CLA-11-03 Question Answer
What happens if you try to compile and run this program?
#include
int main (int argc, char *argv[]) {
char *p = "World";
int i = 2;
switch (p[i]) {
case 'W' :i++; break ;
case 'o' :i += 2; break ;
case 'r' :i += 3; break ;
case '1' :i += 4; break ;
case 'd' :i += 5; break ;
default :i += 4;
}
printf("%d", i);
return 0;
}
-
Choose the right answer:
C++ Institute CLA-11-03 Summary
- Vendor: C++ Institute
- Product: CLA-11-03
- Update on: Jul 20, 2025
- Questions: 40