0
What will be the output of the following C code?
#include <stdio.h>
int main() {
int i;
for (i = 1; i <= 10; i++)
{
if (++i % 2 == 0)
printf("%d ", i);
}
return 0;
}- A1 2 3 4 5 6 7 8 9 10
- B2 4 6 8 10
- C1 3 5 7 9
- D2 4 6 8
Correct answer: B