wayground logo

Free Printable Worksheets

NEW

Font size

S
M
L
XL
Worksheets

Friday

Total questions: 25

Worksheet time: 20mins

Name
Class
Date
1.
a)

1

b)

2

c)

No Limit

d)

Depends on Computer

2.
a)

Operator

b)

Function

c)

Macro

d)

None of These

3.

What is the Output?

a)

20

b)

0

c)

Undefined reference to i

d)

Linking Error

4.

What will be the output of the following?

a)

Compilation Error

b)

0

c)

TechNinjas2

d)

TechNinjas211

5.

Give the Output!

a)

Compilation Error

b)

Runtime Error

c)

__0

d)

__30

6.

What will be the output of the following code?

a)

0

b)

15

c)

Undefined i

d)

Any other Compiler Error

7.

What will pe printed on the screen?

a)

10

b)

20

c)

30

d)

Compilation Error

8.

How many times will the loop run?

a)

5 Times

b)

4 Times

c)

2 Times

d)

1 Time

9.

What will be the Output?

a)

320

b)

60

c)

160

d)

64

10.
a)

Printed infinite times

b)

Prints 1 time only

c)

Nothing is printed

d)

Error

11.
a)

55

b)

54

c)

1

d)

0

12.
a)

Hello is printed 5 times

b)

Compilation Error

c)

Hello is printed 2 times

d)

Hello is printed 3 times

13.
a)

Compilation Error

b)

Runtime Error

c)

Nothing is printed

d)

Hello is printed infinite times

14.

When C Language was invented?

a)

1972

b)

1970

c)

1978

d)

1979

15.

What is storage class for variable A in below code?


void main()

{

int A;

A = 10;

printf("%d", A);

}

a)

extern

b)

auto

c)

register

d)

static

16.
a)

Yes

b)

No

c)

Depends on Compiler

d)

Yes, but RunTime Error

17.
a)

The element will be set to 0.

b)

The compiler would report an error.

c)

The program may crash if some important data gets overwritten.

d)

The array size would appropriately grow.

18.

Guess the output of the following program ?

#include<stdio.h>

int main()

{

int a = 100, b = 200, c = 300;

if(!a >= 500)

b = 300;

c = 400;

printf("%d,%d,%d",a, b, c);

return 0;

}

a)

100,200,400

b)

100,200,300

c)

100,300,400

d)

100,300,300

19.
a)

-3.4e38 to 3.4e38

b)

-32767 to 32768

c)

-32668 to 32668

d)

-32768 to 32767

20.

C was Primarily developed as?

a)

System Programming Language

b)

General Purpose Language

c)

Data Processing Language

d)

None of the above

21.
a)

53 65

b)

65 65

c)

065 65

d)

Syntax Error

22.
a)

0

b)

1

c)

2

d)

3

23.

A C variable cannot start with ?

a)

A number

b)

A special symbol other than underscore

c)

Both, a number as well as underscore

d)

An alphabet

24.
a)

5

b)

6

c)

7

d)

8

25.
a)

21612^{16}-1

b)

21512^{15}-1

c)

2162^{16}

d)

2152^{15}