Objective Questions on Programming Using C

Solapur University MCA (Semester-I) Paper on Programming Using C March 2019

 

Sr. No. Question
1 What is the output of this program?

Void main () {

Double x =28;

Int r;

R=x%5;

Printf(“\n r = %d”, r);}

(a)    R = 3

(b)   Run time Error

(c)    Computing time error

(d)   None of these

2 Which of the following is NOT a keyword of ‘C’?

(a)    Auto

(b)   Register

(c)    Int

(d)   Function

3 Which of the following is NOT a relational operator?

(a)    !

(b)   !=

(c)    >=

(d)   <

4 C is a ___________language

(a)    High level

(b)   Low level

(c)    Middle level

(d)   Machine level

5 The operator && is an example of ______ operator.

(a)    Assignment

(b)   Increment

(c)    Logical

(d)   Relational

   
6 Operators have precedence. A Precedence determines which operator is _________

(a)    Faster

(b)   Takes less memory

(c)    Evaluated first

(d)   Takes no arguments

7 If y is of integer type then the expressions

3* (y-8)/9 and (y-8)/9*3 _________

(a)    Must yield the same value

(b)   Must yield different values

(c)    May or not yield the same value

(d)   None of these

8 The following program fragment

int a = 4, b = 6;

printf(%d”, a ==b);

(a)    Outputs an error message

(b)   Prints 0

(c)    Print 1

(d)   None of these

9 Printf(“%c”, 100); __________

(a)    Prints 100

(b)   Prints ASCII equivalent of 100

(c)    Prints garbage

(d)   None of these

10 The following program

void main()

{

int I = 5;

if (i==5) return;

else printf(“I is not five”);

printf(“over”);

}

results in _________

(a)    Syntax error

(b)   An execution error

(c)    Printing of over

(d)   execution termination without printing anything

   
11 The statement printf(“%d”, (a++)); ________.

(a)    Prints the current value of a

(b)   Prints the current value of a+1

(c)    Prints an error message

(d)   Prints garbage value

12 Prototype of a function means _______

(a)    Name of function

(b)   Output of function

(c)    Declaration of function

(d)   Input of a function

13 Name the loop that executes at least once ______

(a)    For

(b)   If

(c)    Do -while

(d)   While

 14 If there is any error while opening a file, fopen will return

(a)    Noting

(b)   EOF

(c)    NULL

(d)   Depends on compiler

   
  Published on 5th Oct 2021
   

 


Posted

in

by

Tags:

Comments

Leave a Reply

Your email address will not be published. Required fields are marked *