How to implement dynamic data structure in C++ like vector?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Man4ish
    New Member
    • Mar 2008
    • 151

    How to implement dynamic data structure in C++ like vector?

    How dynamic data structure like vectoe can be implemented in C++?

    Thanks
  • Banfa
    Recognized Expert Expert
    • Feb 2006
    • 9067

    #2
    vector is a part of C++ so no need to implement it just use it.

    Or if you mean how is vector implemented that platform defined but something simple with pointers to start, size and capacity held in the vector itself and dynamic allocation of a buffer to hold the data using new.

    Comment

    Working...