Computer Science MCQ Questions with Answer

MCQ Type questions for Competitive Exam.

1. Output of the following program?

int i = 0;
int sum = 0; 
sum = sum + i;

a) 55 b)66 c)45 d)35

2. Which is a valid constructor declaration for the class Students?

a) public String Student( )

b) public float Student( )

c) protected String Student( )

d) public Student ( )

3. What is the output of this C++ program?

int main()
int amount;
amount = 8+2*15;
return 0;

a) 38 b) 34 c)150 d) 90

4. What is the output?

#include <stdio.h>
void main()
char str1[]="CLASS" , str2[] = "CLASS";
printf("Both string are same");
printf("Both string are not same");

a)Both string are same b) Both string are not same

c) compile error d) none

5. Which is called a Wild pointer?

a) Dangling pointer b) Void Pointer

c) Uninitialized pointer d) Null Pointer

6. What is output of C program ?

char c[] = "CSTUDIES";
char *p = c;


7. Unordered list in HTML declare by which tag?

a) <li> b) <ul> c) <ol> d) <dl>

8. what is FTP port number?

a) 20 b) 21 c) Both a & b d) none

9. Which statement is false about SMTP?

a) Connection oriented b) Statefull Protocol

c) Port no. 25 d) ALL of the above

10. Match the following

a) Network Layer 1) Packets

b) Data link Layer 2) Bit

c) Physical Layer 3) Frame

  1. a) – 1), b)-3), c)-2)
  2. a) – 2), b)-1), c)-3)
  3. a) – 3), b)-1), c)-2)

Leave a Comment

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

Scroll to Top