Rajat,
I understand that this was not the most elegant way. To clarify, I had put the
declaration in the header file of the class so that I am sure that the vector
is not destroyed once the function exits. (This is how I debug, I need to
start learning gdb soon :) )
I do need to learn advanced concepts of C++ / cxx11. This is a bit off
topic but can you please recommend a book that focuses on advanced C++ topics.
It is a bit like building a house: you can build a house without really
knowing how to put together beams and bricks, how to properly set windows and
doors, etc. It might stand, and it may serve as shelter. But it will not be
efficient, and who knows what will happen if it rains or if a storm comes.
That's how I see programming: you can try to get a program together without
knowing the difference between stack and heap, or how C++ the lifetime of
variables. Your program may run, but it's not going to be efficient, nor will
you have any confidence in its correctness.
You don't have to know *advanced* concepts, but you should know at least the
basics. I always think that the book by Stroustrup is a good starting point,
but there are many others that are also good.
Best
W.
--
------------------------------------------------------------------------
Wolfgang Bangerth email: bange...@colostate.edu
www: http://www.math.colostate.edu/~bangerth/
--
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see
https://groups.google.com/d/forum/dealii?hl=en
---
You received this message because you are subscribed to the Google Groups "deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to dealii+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.