Question PRG-C-0044
MediumWhat is the output of this program?
#include <stdio.h>
int main() {
int i, s = 0;
for (i = 0; i < 10; i++) {
if (i % 3 == 0) continue;
if (i == 8) break;
s += i;
}
printf("%d %d", s, i);
return 0;
}
- A.
21 8
- B.
27 10
- C.
Sign up free to see the answer and a step-by-step explanation.