iGET

Computer Knowledge - MCQ Practice Questions

Practice free Computer Knowledge multiple-choice questions with detailed answers and explanations. Perfect for competitive exam preparation.

309 questions | 100% Free

Q.101Easy

What will be the output of: char *s = "Hello"; printf("%d", strlen(s));

Q.102Medium

What will be the output of: int x = 5; printf("%d", x << 1);

Q.103Medium

Consider the code: int arr[10]; int *p = arr; What is p[5]?

Q.104Medium

What is the purpose of the void pointer in C?

Q.105Easy

What will be the output of: #define MAX 10; int x = MAX; printf("%d", x);

Q.106Medium

Which function is used to read a string from standard input?

Q.107Hard

What will be the output of: int x = 10; int y = x++ + ++x; printf("%d", y);

Q.108Medium

What is the output of: int arr[] = {1,2,3,4,5}; printf("%d", sizeof(arr)/sizeof(arr[0]));

Q.109Easy

Which of the following correctly initializes a 2D array?

Q.110Easy

What will be the output of: printf("%d", );

Q.111Easy

What does the getchar() function do?

Q.112Easy

What will be the output of: int a = 5, b = 5; if(a == b) printf("Equal"); else printf("Not Equal");

Q.113Medium

What will be the output of: char c = 'A'; printf("%d", c);

Q.114Hard

Consider a complex expression: int x = 2 + 3 * 4 - ; What is x?

Q.115Easy

Which header file is essential for using the printf() function in C?

Q.116Medium

What is the output of: int arr[5]; printf("%d", sizeof(arr));

Q.117Medium

Which function is used to allocate memory dynamically at runtime?

Q.118Medium

What is the purpose of the break statement in a switch case?

Q.119Medium

What will be the output of: int x = 5, y = 10; if (x < y) printf("yes"); else printf("no");

Q.120Medium

Which of the following is NOT a valid way to pass arguments to a function in C?

Computer Knowledge MCQs Free Practice – iGET | iGET