Tuesday, May 29, 2012

C questions and answers


C questions and answers with explanation



1. Data types 2. Operators 3. Pointers

4. Arrays 5. Loops 5. Preprocessor

6. Structures 6. If else 6. Switch case

7. printf 8. Variables 7. File handling

8. Strings 9. Command line arguments



C questions and answers for interview


1. FAQ

Sunday, May 27, 2012

Debugging questions in c with answers





C debugging interview questions

C debugging questions with answers




1. Write a c program too shutdown
window operating system in TURBO C.


void main(void)
{
system("shutdown -s");
}

Save the above .Let file name is close.c and compile and execute the above
program. Now close the turbo c compiler and open the directory in window you
have saved the close.c (default directory c:\tc\bin)

Aptitude questions and answers in c

C
programming aptitude questions and answers




Aptitude
questions in interview




Total question: 32

Time: 60 minute

Total marks: 64



1. Find out the error if any, in the program.



#include

int main(){

int i=1;

switch(i){

case 1: printf("\radioactive cats have 18 half-lives");

break;

case 1*2+4: printf("\bottle for rent -inquire within");

C basic questions



C
basic interview questions and answers for freshers





(1)



void main(){

char i;

clrscr();

for(i=120;i<=128;i++){

printf("%d ",i);



}

getch();

}



Output: Infinite loop



(2)



void main(){

int i;

clrscr();

for(i=0,i++,i<=5;i++,i<=2;i=0,i<=5,i+=3){

printf("%d ",i);

}

getch();

}



Output: 2

(3)



void main(){

Multiple choice questions in c