You are not logged in.

#1 2015-09-14 05:49:17

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

C Language Operators And Expressions Program Code:

C Programming Quizzes C Language Operators And Expressions

Directions:
Determine output of the following program code.

Question:
#include<stdio.h>
void main()
{
   int a, b=7;
   a = b<4 ? b<<1 : ++b>4 ? 7>>1 : a;
   printf("%d %d", a, b);
}

Option A):
3 8
Option B):
3 7
Option C):
8 3
Option D):
7 3

Correct Answer is Option A):
3 8


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

2015-09-14 05:49:17

Advertisement
Ads By Google

Re: C Language Operators And Expressions Program Code:



Board footer