You are not logged in.

#1 2015-09-15 05:58:40

husnain
User RankUser RankUser RankUser RankUser RankUser Rank
Administrator
From: Chichawatni,Pakistan
Registered: 2014-10-03
Posts: 8,129
Website

Syntax Error:

C Programming Quizzes C Language Control Structures

Directions:
Consider the following code:
void main()
{
   int a[5] = {6,8,3,9,0}, i=0;
   if(i != 0)
   {
      break;
      printf("%d", a[ i ]);
   }
   else
      printf("%d", a[i++]);
}

Question:
What is the output of the above program?

Option A):
No output
Option B):
Runtime error
Option C):
8
Option D):
Syntax error

Correct Answer is Option D):
Syntax error


You cannot discover the new oceans unless you have the courage to lose the sight of the shore.

2015-09-15 05:58:40

Advertisement
Ads By Google

Re: Syntax Error:



\n

Board footer