Question PRG-CPP-0078
HardWhat is the difference between std::array and std::vector?
- A.
They are identical
- B.
std::array is slower
- C.
Sign up free to see the answer and a step-by-step explanation.
Popular companies
Prepare company by company
Hiring pattern, syllabus, past questions and mocks for each company.
All companiesPractice by subject
C++ question
What is the difference between std::array and std::vector?
They are identical
std::array is slower
Sign up free to see the answer and a step-by-step explanation.
std::vector can't hold ints
std::array has a fixed size known at compile time; std::vector can grow at run time