Go4Expert

Go4Expert (http://www.go4expert.com/)
-   C (http://www.go4expert.com/articles/c-tutorials/)
-   -   100 Multiple choice questions in C (http://www.go4expert.com/articles/100-multiple-choice-questions-c-t1373/)

shabbir 22Aug2007 21:48

Re: 100 Multiple choice questions in C
 
what explanation you want for the function.

sudheer157 22Aug2007 21:51

Re: 100 Multiple choice questions in C
 
Hi
I Want Solutin For Q No 67..

shabbir 23Aug2007 08:24

Re: 100 Multiple choice questions in C
 
Quote:

Originally Posted by sudheer157
Hi
I Want Solutin For Q No 67..

Choice is 4

indian.21987 27Aug2007 19:48

Re: 100 Multiple choice questions in C
 
*question number 1*/

Code:
int z,x=5,y=-10,a=4,b=2;
z = x++ - --y * b / a;What number will z in the sample code above contain?




In this,I think the answer is 10
But It is given that 12 is the ans.
How is it possible?
Please can you explain it?
Thank you.

shabbir 27Aug2007 22:02

Re: 100 Multiple choice questions in C
 
Why don't you try and Run it on your compiler and see what is the output.

sudheer157 31Aug2007 23:44

Re: 100 Multiple choice questions in C
 
Hi can some one please tell me the answers for the following
Q19
Q45
Q64
Q69
Thanks in advance.

shabbir 1Sep2007 07:13

Re: 100 Multiple choice questions in C
 
Hi can some one please tell me the answers for the following
Quote:

Originally Posted by sudheer157
Q19

I would go for choice 1 as other are not relevant to the cause of the problem.
Quote:

Originally Posted by sudheer157
Q45

Choice 4 and the choice itself tells the reason
Quote:

Originally Posted by sudheer157
Q64

Choice 2 as the pointer base address is changed by p++
Quote:

Originally Posted by sudheer157
Q69

Choice 1 and the reason lies in the choice option itself.

sudheer157 1Sep2007 23:24

Re: 100 Multiple choice questions in C
 
THANQ so much...for your reply...i need solutions to few more.i will be very thankful to you and i need solutions for the following
Q72
Q75
Q83
Q96
Q100
please help me out.

shabbir 2Sep2007 07:31

Re: 100 Multiple choice questions in C
 
Here they come.
Quote:

Originally Posted by sudheer157
Q72

Choice is 3
Quote:

Originally Posted by sudheer157
Q75

Discussion is there in the comments.
Quote:

Originally Posted by sudheer157
Q83

I would vote for choice 4
Quote:

Originally Posted by sudheer157
Q96

Choice 1 and if you have doubt in such a small question you should refer to some standard C book.
Quote:

Originally Posted by sudheer157
Q100

private is not a C keyword and so I would go for choice 1.

sudheer157 6Sep2007 14:48

Re: 100 Multiple choice questions in C
 
hi shabbir
ihave doubts in the following questions please help me out.i m attaching those questions in a zip file as they are bmp images.
please give me the solutions either to my mail sudheer157@yahoo.com or in this forum itself.

<<Attachment Removed>>


All times are GMT +5.5. The time now is 10:00.