Interview Questions
- What is the output of printf(“%d”)?
output window garbage value.
- Difference between “calloc(…)” and “malloc(…)”?
of elements of a certain size.
malloc(…) allocated bytes of memory and not blocks
of memory like calloc(…).
- Can I include other file in place of .h with #include?
you mention, eg: #include<macros.inc>, the file
macros.inc will be included.
- Difference between “printf(…)” and “sprintf(…)”?
printf() Used to write data to the standard output device.
- How to reduce a final size of executable?
- What are the different storage classes in C?
- Difference between Strings and character arrays?
will not. Unless you explicitly specify with static keyword.
- How to determine the size of an allocated portion of memory?
- Difference between static memory allocation and dynamic memory allocation?
required memory space for a declared variable, whereas
in dynamic memory allocation functions malloc( ) or
calloc( ) is used to get memory dynamically.
- What is the difference between arrays and pointers?
address, Arrays are collection of similar data types.
0 comments:
Post a Comment