C Code Interview Questions
Questions Answers Views Company eMail

#define prod(a,b) a*b main() { int x=3,y=4; printf("%d",prod(x+2,y-1)); }

1 15264

main() { unsigned int i=65000; while(i++!=0); printf("%d",i); }

1 14970

main() { int i=0; while(+(+i--)!=0) i-=i++; printf("%d",i); }

CSC, GoDB Tech, IBM,

9 36287

main() { float f=5,g=10; enum{i=10,j=20,k=50}; printf("%d\n",++k); printf("%f\n",f<<2); printf("%lf\n",f%g); printf("%lf\n",fmod(f,g)); }

1 6926

main() { int i=10; void pascal f(int,int,int); f(i++,i++,i++); printf(" %d",i); } void pascal f(integer :i,integer:j,integer :k) { write(i,j,k); }

1 8075

void pascal f(int i,int j,int k) { printf(ā€œ%d %d %dā€,i, j, k); } void cdecl f(int i,int j,int k) { printf(ā€œ%d %d %dā€,i, j, k); } main() { int i=10; f(i++,i++,i++); printf(" %d\n",i); i=10; f(i++,i++,i++); printf(" %d",i); }

1 9322

What is the output of the program given below main() { signed char i=0; for(;i>=0;i++) ; printf("%d\n",i); }

1 3687

main() { unsigned char i=0; for(;i>=0;i++) ; printf("%d\n",i); }

1 5368

main() { char i=0; for(;i>=0;i++) ; printf("%d\n",i); }

2 13121

Is the following statement a declaration/definition. Find what does it mean? int (*x)[10];

1 5136

What is the output for the program given below typedef enum errorType{warning, error, exception,}error; main() { error g1; g1=1; printf("%d",g1); }

1 6259

typedef struct error{int warning, error, exception;}error; main() { error g1; g1.error =1; printf("%d",g1.error); }

1 5459

#ifdef something int some=0; #endif main() { int thing = 0; printf("%d %d\n", some ,thing); }

1 4592

#if something == 0 int some=0; #endif main() { int thing = 0; printf("%d %d\n", some ,thing); }

1 5849

What is the output for the following program main() { int arr2D[3][3]; printf("%d\n", ((arr2D==* arr2D)&&(* arr2D == arr2D[0])) ); }

1 4875


Post New C Code Questions

Un-Answered Questions { C Code }

write a simple calculator c program to perform addition, subtraction, mul and div.

3136


Write a program to model an exploding firecracker in the xy plane using a particle system

3683


Write a Program in 'C' To Insert a Unique Number Only. (Hint: Just Like a Primary Key Numbers In Database.) Please Some One Suggest Me a Better Solution for This question ??

1768


how to create a 3x3 two dimensional array that will give you the sums on the left and bottom columns

3117


why nlogn is the lower limit of any sort algorithm?

2369






could you please send the program code for multiplying sparse matrix in c????

3063


3) Int Matrix of certain size was given, We had few valu= es in it like this. =97=97=97=97=97=97=97=97=97=97=97 1 = | 4 | | 5 | &= nbsp; | 45 =97=97=97=97=97=97=97=97=97=97=97 &n= bsp; | 3 | 3 | 5 | = | 4 =97=97=97=97=97=97=97=97=97=97=97 34 |&nbs= p; 3 | 3 | | 12 | &= nbsp; =97=97=97=97=97=97=97=97=97=97=97 3 | &nbs= p; | 3 | 4 | = | 3 =97=97=97=97=97=97=97=97=97=97=97 3 | = ; | | | = ; 3 | =97=97=97=97=97=97=97=97=97=97=97 &= nbsp; | | 4 | = ; | 4 | 3 We w= ere supposed to move back all the spaces in it at the end. Note: = If implemented this prog using recursion, would get higher preference.

3317


Design an implement of the inputs functions for event mode

2955


To Write a C program to remove the repeated characters in the entered expression or in entered characters(i.e) removing duplicates. String contains only lowercase characters ['a'-'z']

488


write a program for area of circumference of shapes

2026


Cluster head selection in Wireless Sensor Network using C programming language.

3101


What is data _null_? ,Explain with code when u need to use it in data step programming ?

2814


Hi, i have a project that the teacher want a pyramid of numbers in C# or java...when we click a button...the pyramid should be generated in a listbox/or JtextArea...and the pyramid should have the folowing form: 1 232 34543 4567654 567898765 67890109876 7890123210987 890123454321098 90123456765432109 0123456789876543210 Plz help with codes...didn't find anything on the net.

2673


Write a routine to implement the polymarker function

4373


create a C-code that will display the total fare of a passenger of a taxi if the driver press enter,the timer will stop. Every 10 counts is 2 pesos. Initial value is 25.00

6304