Skip to content

Category Archives: Quizzes

Consider a compiler where int takes 4 bytes, char takes 1 byte and pointer takes 4 bytes. #include <stdio.h>    int main() {     int arri[]… Read More
Output of following program? #include <stdio.h>    int main() {     int *ptr;     int x;        ptr = &x;     *ptr = 0;        printf(" x =… Read More
Output of following program? # include <stdio.h> void fun(int *ptr) {     *ptr = 30; }    int main() {   int y = 20;   fun(&y);   printf("%d",… Read More
What is the output of following program? # include <stdio.h> void fun(int x) {     x = 30; }    int main() {   int y =… Read More
Consider the following C declaration struct {      short s[5];     union {           float y;           long z;      }u;  } t; Assume that objects of the type short,… Read More
struct node  {     int i;     float j;  };  struct node *s[10]; The above C declaration define ‘s’ to be (GATE CS 2000) (A) An array,… Read More
Assume that size of an integer is 32 bit. What is the output of following program? #include<stdio.h> struct st {     int x;     static int y;… Read More
#include‹stdio.h› int main() {     struct site     {         char name[] = "GeeksQuiz";         int no_of_pages = 200;     };     struct site *ptr;     printf("%d ", ptr->no_of_pages);     printf("%s", ptr->name);     getchar();… Read More
Output of following program? #include <stdio.h> int f1() { printf ("Geeks"); return 1;} int f2() { printf ("Quiz"); return 1;}    int main() {   int… Read More
Output of following program? #include <stdio.h> int main() {     int i = 5;     printf("%d %d %d", i++, i++, i++);     return 0; } (A) 7 6… Read More
What is the output of following program? #include <stdio.h> #define macro(n, a, i, m) m##a##i##n #define MAIN macro(n, a, i, m)    int MAIN() {… Read More
What is the output of following function for start pointing to first node of following linked list? 1->2->3->4->5->6 void fun(struct node* start) {   if(start ==… Read More
What is the output of following program? #include<stdio.h> void swap(char *str1, char *str2) {   char *temp = str1;   str1 = str2;   str2 = temp; }  … Read More
What is the output of following program? # include <stdio.h>    int main() {    char str1[] = "GeeksQuiz";    char str2[] = {'G', 'e', 'e', 'k',… Read More
#include <stdio.h> #if X == 3     #define Y 3 #else     #define Y 5 #endif    int main() {     printf("%d", Y);     return 0; } What is… Read More

Start Your Coding Journey Now!