You are not logged in.

#1 2015-09-15 05:49:46

hasnain
Administrator
From: Chichawatni
Registered: 2014-10-13
Posts: 8,355
Website

Digit Value:

http://interviewquestionsanswers.org/quiz/C-Programming http://interviewquestionsanswers.org/qu … Structures

Directions:
What will be the final value of the digit?

Question:
void main()
{
   int digit = 0;
   for( ; digit <= 9; )
   digit++;
   digit  *= 2;
   --digit;
}

Option A):
12
Option B):
14
Option C):
51
Option D):
19

Correct Answer is Option D):
19


Failure is the first step towards seccess.

2015-09-15 05:49:46

Advertisement
Ads By Google

Re: Digit Value:



Board footer