C programming challenge Online Test

#include <stdio.h>

void main()


void foo();

printf("1 ");



void foo()


printf("2 ");


How will you free the allocated memory ?

What is the similarity between a structure, union and enumeration?


int main()




return 0;


The keyword used to transfer control from a function back to the calling function is

Can you combine the following two statements into one?

char *p;

p = (char*) malloc(100);

In which header file is the NULL macro defined?

If a variable is a pointer to a structure, then which of the following operator is used to access data members of the structure through the pointer variable?

A pointer is

What is the purpose of "rb" in fopen() function used below in the code?

FILE *fp;

fp = fopen("source.txt", "rb");


Raushan Singh

can any one help me how the output of question number 5.(@D array) came.

1884 days 6 hours 36 minutes ago

Raushan Singh

in first in 4th question the programe is not complied because stdio.h header file not included.and also function is not decleare.so it gibes compiler error.

1884 days 6 hours 37 minutes ago

Davit Jibuti

in first test there is no prototype, if you are writing #include option then you should write prototype of function for us to see :), that it's not mistake

2286 days 2 hours 53 minutes ago

Davit Jibuti

there is no prototype.

2286 days 2 hours 55 minutes ago

1 Follower
Tests: 2

Your Facebook Friends on WizIQ

More Tests By Author

Microprocessor 8085`
20 Questions | 841 Attempts