iGET

Computer Knowledge - MCQ Practice Questions

Computer Science questions in competitive exams stay close to fundamentals, which is good news if you revise the right five subjects. Coverage includes data structures, algorithms and complexity, operating systems, database management systems, computer networks, and computer organisation. Explanations show the trace or the state table where one helps, since seeing the intermediate steps is what makes the concept stick.

304 questions | 100% Free

Q.1Easy

What is the output of the following C code?
int x = 5;
printf("%d", x++);

Q.2Easy

Which of the following is the correct syntax to declare a pointer in C?

Q.3Easy

What will be the size of the following array in bytes?
char arr[10];

Q.4Easy

What is the purpose of the 'void' keyword in C?

Q.5Easy

What is the output of the following C code?
int a = 10, b = 20;
int c = (a > b) ? a : b;
printf("%d", c);

Q.6Easy

What does the strlen() function return?

Q.7Easy

Which header file is required to use the printf() function in C?

Q.8Easy

Which of the following is a valid variable name in C?

Q.9Easy

What is the return type of the strlen() function?

Q.10Easy

Which operator has the highest precedence in C?

Q.11Easy

What is the size of an integer variable in most modern C compilers?

Q.12Easy

Which of the following is NOT a valid C data type?

Q.13Easy

What is the purpose of the & operator in C?

Q.14Easy

Which keyword is used to create a constant variable in C?

Q.15Easy

What is the output of sizeof(char) in C?

Q.16Easy

How many times will the loop execute?
for(int i = 0; i < 5; i++)

Q.17Easy

What will be the value of x after: int x = 5; x += 3;

Q.18Easy

What is the size of int data type in a 32-bit system?

Q.19Easy

Which header file is required to use the printf() function?

Q.20Easy

In C, which operator has the highest precedence?