Destruction of local object, C/C++ Programming

Need assignment help

What's the order that local objects are destructed?

Posted Date: 2/13/2013 1:26:37 AM | Location : United States





In opposite order of construction: First constructed, last destructed.   

In the following instance, b''s destructor will be executed first, as compared to the a''s destructor: 

example will help you

void userCode()

{

Fred a;

Fred b;

...

}

Posted by Robert | Posted Date: 2/13/2013 1:27:49 AM


Related Discussions:- Destruction of local object, Assignment Help, Ask Question on Destruction of local object, Get Answer, Expert's Help, Destruction of local object Discussions

Write discussion on Destruction of local object
Your posts are moderated
Related Questions

in this problem u given a board in which some of the elements are placed as shown in diagram below .each element represent a color .fill the other elements in the board such that n

polishing the jewel game with c coding


Write a program to find the area under the curve y = f(x) between x = a and x = b, integrate y = f(x) between the limits of a and b.   #include float start_poin

dispaly the last ant on rod


Working Ordered linked list: • Eachinteger in the queue is stored inside of a QueueItem. The QueueItem contains the integer, and a pointer to the next item in the queue. Fo

6999066263304447777077766622337778 -----> message sent by the first smuggler. my name is robert---------> message decoded by the second smuggler. Where ‘0’ denotes the "space". Ex

C Program to Check  EVEN & ODD NO   main() {           int n, a;           clrscr();           printf("ENTER ANY NUMBER: ");           scanf("%d", &n);