R4R
Right Place For Right Person TM
 
R4R C C FAQs C Subjective Questions and Answers

 


Totel:206 Click: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42

C Interview Questions And Answers

Page 1

 What is C language?

programming language

C is a middle level programing language. C is a
structured, procedural programming language.c 
widely used both for operating systems and 
applications.C is also called a system progmming 
language

The c language is  a programming language

C is high level language.

 C is a Structured Oriented Programming Language

c is structure programing language.

middle level,structured prigramming language

C is a middle level Programming language

 What is the output of printf("%d")?

0

0

Any integer value

Any integer value

the output of this statement depends on data types %d is the data type of int type variabe if you will declare the variable in declaration part suppose u will declare int i so the output of this statement is i...............

the output of this statement depends on data types %d is the data type of int type variabe if you will declare the variable in declaration part suppose u will declare int i so the output of this statement is i...............

garbegge value

garbage integer value

Garbage Value

 What is the difference between "calloc(...)" and "malloc(...)"?

Some important distance between calloc and malloc are given below:
 
malloc:
 
malloc takes only the "size" of the memory block to be allocated as input parameter.
malloc allocates memory as a single contiguous block.
if  a single contiguous block cannot be allocated then malloc would fail.

calloc:

calloc takes two parameters: the number of memory blocks and the size of each block of memory
calloc allocates memory which may/may not be contiguous.
all the memory blocks are initialized to 0.
it follows from point 2 that, calloc will not fail if memory can beallocated in non-contiguous blocks when a single contiguous blockcannot be allocated.

malloc: malloc create the single block of given size by user
calloc: calloc creates multiple blocks of given size
both return void pointer(void *)so boh requires type casting
malloc: eg:
int *p;
p=(int*)malloc(sizeof(int)*5)
above syntax tells that malloc occupies the 10 bytes memeory and assign the address of first byte to P

calloc: eg:
p=(int*)calloc(5,sizeof(int)*5)
above syntax tells that calloc occupies 5 blocks each of the 10 bytes memeory and assign the address of first byte of first block to P

 What is the difference between "printf(...)" and "sprintf(...)"?

the printf() function is supposed to print the output to stdout.In sprintf() function we store the formatted o/p on a string buffer.

"printf(....)"  is standard output statement
 and 
 "sprintf(......)" is formatted output statement

print will use for the show some output on screen.output will in any data type

and sprintf we are output only string and character.

 How to reduce a final size of executable?

Do not include unnecessary header files and 
Do not link with unneccesary object files.

  

Use dynamic linking. 


Goto Page:

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42

C Objective Questions And Answers

C Objective Questions And Answers

C Interview Questions And Answers

C Interview Questions And Answers


R4R,C Objective fresher and experienced, C Subjective fresher and experienced ,C Interview Questions And Answers,C fresher and experienced,C Interview fresher and experienced ,C Questions fresher and experienced,C Answers fresher and experienced

This section covers C interview questions and answers for fresher and experienced . In this section we covers C interview questions for experienced ,C interview questions for freshers .

This section covers C Objective interview questions and answers for fresher and experienced. In this section we covers C Objective interview questions for experienced ,C Objective interview questions for freshers

This section covers C Subjective interview questions and answers for fresher and experienced. In this section we covers C Subjective interview questions for experienced ,C Subjective interview questions for freshers

Tutorials,Examples,Questions and Answer

R4R
R4R
R4R
R4R
R4R
R4R
R4R
R4R