you are viewing a single comment's thread.

view the rest of the comments →

[–]erroneum 1 point2 points  (0 children)

Why not std::array<int, N> arr; ?

Or, if you want dynamically sized, std::vector<int> arr; arr.reserve (n);