Академический Документы
Профессиональный Документы
Культура Документы
Search
Interview Q&A Videos Placement papers HR interview CV Cover letter GD Aptitude Online practice tests Java tutorial .NET tutorial Log In Buy
Interview Questions
Interview Online
After Interview
Interview questions
C interview part 1
C interview part 2
C interview part 3
C interview part 4
C interview part 6
C interview part 7
C interview part 8
ANSWER - It allocates memory blocks and returns a void pointer to the allocated space, or NULL if there is insufficient memory available.
C interview part 5
C interview part 9
C interview part 10
C interview part 11
C interview part 12
C interview part 13
C interview part 14
C interview part 15
C Bit operations
31/07/2013
C preprocessor
C Structures and Union
QUESTION - Recursive data structures are almost always implemented with memory from the __________
-stack
Placement
practice test: Java | SAP | .NET | Oracle | Sql Server | QA | Aptitude | Networking | All Skills
-heap
-processor
-RAM
View Answer / Hide Answer
ANSWER - heap
QUESTION - static variables are local in scope to the block or file in which they are defined, but their lifespan is
throughout the program.
careerride.com/C-Interview-Questions.aspx
2/16
31/07/2013
-True
-False
View Answer / Hide Answer
ANSWER - True
QUESTION - One that can be modified by the class even when the object of the class or the member function
doing the modification is const it is known as______________
-member function
-mutable member
-constant member
-none of these
View Answer / Hide Answer
ANSWER - mutable member
QUESTION - A __________is a single-parameter constructor that is declared without the function specifier
explicit.
-converting constructor
-copy constant
-dangling pointer
-none of these
View Answer / Hide Answer
ANSWER - converting constructor
QUESTION - What function should be used to release allocated memory which is no longer needed?
-free()
-dealloc()
-release()
-dropmem()
-unalloc()
View Answer / Hide Answer
careerride.com/C-Interview-Questions.aspx
ANSWER - free()
3/16
31/07/2013
ANSWER - free()
QUESTION - What function should be used to free the memory allocated by calloc() ?
-dealloc();
-malloc(variable_name, 0)
-free();
-memalloc(variable_name, 0)
View Answer / Hide Answer
ANSWER - free();
QUESTION - In C, if you pass an array as an argument to a function, what actually gets passed?
careerride.com/C-Interview-Questions.aspx
4/16
31/07/2013
QUESTION - The library function used to find the last occurrence of a character in a string is
-strnstr()
-laststr()
-strrchr()
-strstr()
View Answer / Hide Answer
ANSWER - strrchr()
5/16
31/07/2013
- These subscript values are used to identify the elements in the array.
- Since subscripts start at 0,arrays are said to use zero-based addressing.
6/16
31/07/2013
How does placing some code lines between the comment symbol help in debugging the code?
careerride.com/C-Interview-Questions.aspx
7/16
31/07/2013
- Placing comment symbols /* */ around a code isolates some code that the coder believes might be causing the errors in the program,
without deleting it. - If the code is correct, you can just remove the comment symbols, without needing to retype it.
- If it is wrong, you can just remove it.
8/16
31/07/2013
Are comments included during the compilation stage and placed in the EXE file as well?
- No, comments encountered by the compiler are disregarded.
- Their only purpose is guidance and ease of programmer. They have no effect on the functionality of the program.
Define the scope of static variables.
The scope of a static variable is local to the block in which the variable is defined..............
Read answ er
A bus error indicates an attempt to access memory in an illegal way,perhaps due to an unaligned pointer...........
9/16
31/07/2013
A bus error indicates an attempt to access memory in an illegal way,perhaps due to an unaligned pointer...........
Read answ er
Define recursion in C
A programming technique in which a function may call itself. Recursive programming is especially well-suited to parsing nested markup
structures.............
Read answ er
10/16
31/07/2013
The difference between arrays and linked lists are: - Arrays are linear data structures. Linked lists are linear and non-linear data
structures............
Read answ er
Describe about storage allocation and scope of global, extern, static, local and register variables
The storage allocation / class determine the memory part where the storage space is allocated for variables, functions and how long the
allocation of storage continues to exist............
Read answ er
Define register variables. What are the advantages of using register variables?
The variables of register type modifier will inform the compiler for storing the variables in a register of CPU.............
Read answ er
Can we specify variable field width in a scanf() format string? If possible how?
It is possible to specify variable field width in a scanf() format string. By using %s control string...........
Read answ er
Out of fgets() and gets() which function is safe to use and why?
The function fgets() function is safer to use. It checks the bounds.........
Read answ er
For char[] array, such size is not accepted by the compiler. If the size is specified, the following are the differences between char *a and char
11/16
31/07/2013
For char[] array, such size is not accepted by the compiler. If the size is specified, the following are the differences between char *a and char
a[]...........
Read answ er
12/16
31/07/2013
13/16
31/07/2013
14/16
31/07/2013
class t {
public:
t(float x);
t(float r); // ERROR: Overload is Ambiguous: t::t(float)
};
int main()
{
t p = t(5.7); // Ambiguous: Which coordinate system?
// Your statements
}
To solve this ambiguity we use the Named Constructor Idiom:
careerride.com/C-Interview-Questions.aspx
15/16
31/07/2013
Home | Want a Job? Submit Key Skills | Employer login | My key skills | About us | Sitemap | Contact us
Copyright 2008 - 2010 CareerRide.com. All rights reserved. Terms of use | Follow us on Facebook!
Bookm ark to:
careerride.com/C-Interview-Questions.aspx
16/16