What is the Difference between "vector" and "array"?
Answer Posted / vivek
in vector space is not fixed,but in array space is fixed
second vector has memory allocation is dynamic which is
unsuitable at execution time but in array memory allocation
is continuously
array contain same datatype it is not in vector
array has compatibility to use 2d,3d arrayalso
| Is This Answer Correct ? | 3 Yes | 1 No |
Post New Answer View All Answers
Define stacks. Provide an example where they are useful.
Should a constructor be public or private?
Explain the concept of memory leak?
How do you compile the source code with your compiler?
What is endl?
Write a Program for read a line from file from location N1 to N2 using command line arguments. Eg:exe 10 20 a.c
What is difference between array and vector in c++?
Write a struct time where integer m, h, s are its members?
Using a smart pointer can we iterate through a container?
What is the output of the following program? Why?
Why should we use null or zero in a program?
What is class invariant in c++?
How to implement is-a and has-a class relationships?
What is general format for a prototype?
What is the rule of three?