Back

Explore Courses Blog Tutorials Interview Questions
0 votes
2 views
in Technology Trends by (45k points)

#include<stdio.h>

int c[10] = {1,2,3,4,5,6,7,8,9,10};  

main()

{

   int a, b=0;

   for(a=0;a<10;++a)

      if(c[a]%2 == 1)

         b+=c[a];

   printf("%d", b);

}

A) 20

B) 24

C) 25

D) 30

E) None of these

1 Answer

0 votes
by (99k points)

The correct answer to the question “What will be the output of the following program” is option ©. 25. And all other options are incorrect. If you wish to get started by learning Programming Languages, I recommend you take up the online Programming courses and watch the Fastest Way to Learn Programming video.

Related questions

0 votes
1 answer
0 votes
1 answer

Browse Categories

...