What is the difference between an ARRAY and a LIST in C++?



What is the difference between an ARRAY and a LIST in C++?..

Answer / nashiinformaticssolutions

Although lists and arrays are both used to store data, they differ in a few important ways. These consist of:

• A list's size is changeable, but an array's is fixed.
• While a list allows sequential access, in which the user must navigate through the elements to locate a given index, an array allows random access using indexes.

• While a list can store entries in any memory location, an array stores elements in contiguous memory.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More C++ Interview Questions

Tell us the size of a float variable.

0 Answers   Accenture,


Without using third variable write a code to swap two numbers.

0 Answers   Accenture,


What is the meaning of the following declaration: int *const *const *i?

0 Answers   Adobe,


How many times will this loop execute? Explain your answer.

0 Answers  


What are the advantages and disadvantages of B-star trees over Binary trees?

0 Answers  


Write a C++ Program to Find Sum and Average of three numbers.

1 Answers  


What is an abstract class in C++

0 Answers   SwanSoft Technologies,


Name the operators that cannot be overloaded.

1 Answers   Wipro,


What is constant keyword in C++? Illustrate its various uses.

0 Answers   Akamai Technologies, Infogain,


Discuss about iteration statements in C++ .

0 Answers   Agilent,


Briefly explain various access specifiers in C++.

0 Answers   Amdocs,


If class D is derived from a base class B

0 Answers  


Categories