Difference between linked list and array?

Answers were Sorted based on User's Feedback



Difference between linked list and array?..

Answer / shyamu sharma

Linked List is dynamic, Array is static.
Searching : Fast in Linked List, Slow in Array.
Array is fixed length, Linked List Unlimited till Memory end.

Is This Answer Correct ?    12 Yes 1 No

Difference between linked list and array?..

Answer / truong nguyen

Memory address of items in the array are continues but they
are not continues in the linked list. So you will easily to
access one item in an array, but not for a linked list.
However, you can easily insert or remove one item into/from
a linked list.

Is This Answer Correct ?    8 Yes 1 No

Difference between linked list and array?..

Answer / nisha

linked list can be implemented dynamically

Is This Answer Correct ?    1 Yes 0 No

Post New Answer

More C++ General Interview Questions

Reads in the size of a square from the screen; 2. Prints a hollow square of that size out of “-“, “|” and blanks on screen; 3. Prints the same hollow square onto a text file. Your program should work for squares of all side sizes between 1 and 20. --- │ │ │ │ │ │ ---

0 Answers  


What is a c++ object?

0 Answers  


What is a dangling pointer?

3 Answers   Glenwood,


What is a singleton class c++?

0 Answers  


How do you define a class in c++?

0 Answers  






Write a program which employs Recursion

0 Answers  


What is operator overloading in c++ example?

0 Answers  


Read the following program carefully and write the output of the program. Explain each line of code according to given numbering. #include <stdio.h> #include <unistd.h> #include <stdlib.h> #include <errno.h> 1……………… int main (void) { pid_t pid; 2………………………… pid = fork(); 3…………………………. if (pid > 0) { int i; 4………………………… for (i = 0; i < 5; i++) { 5………………… …………… printf(" I AM VU : %d\n", i); 6………………… …………… sleep(1); } exit(0); } 7………………… ……… else if (pid == 0) { int j; for (j = 0; j < 5; j++) { 8……………………………… printf(" I have no child: %d\n", j); sleep(1); } _exit(0); } else { 9………………………………fprintf(stderr, "can't fork, error %d\n", errno); 10……………… … ………… exit (EXIT_FAILURE); } }

1 Answers  


Explain abstraction.

0 Answers  


Should the this pointer can be used in the constructor?

0 Answers  


Will this c++ program execute or not?

0 Answers  


Explain working of printf?

8 Answers  


Categories