Name an advantage of array over linked list?

Answer Posted / eren tsanglao

Array can be access randomly and it can even access the
middle element by just the array name with the
subscript,eg, a[5].The elemente are allocated a contagious
memory.Whereas in linked list more space is required for
the pointer and the information.Accessing elements in
linked list is sequential.

Is This Answer Correct ?    26 Yes 7 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Why do we use polymorphism in oops?

575


#include #include #include #include void select(char *items, int count); int main(void) { char s[255]; printf("Enter a string:"); gets(s); select(s, strlen(s)); printf("The sorted string is: %s.\n", s); getch(); return 0; } void select(char *items, int count) { register int a, b, c; int exchange; char t; for(a = 0; a < count-1; ++a) { exchange = 0; c = a; t = items[ a ]; for(b = a + 1; b < count; ++b) { if(items[ b ] < t) { c = b; t = items[ b ]; exchange = 1; } } if(exchange) { items[ c ] = items[ a ]; items[ a ] = t; } } } design an algorithm for Selection Sort

2064


What is stream in oop?

836


What is meant by multiple inheritance?

732


How do you define a class in oop?

625






What is polymorphism in oop example?

513


How can you overcome the diamond problem in inheritance?

763


what is different between oops and c++

1999


What are different oops concepts?

570


What is abstraction encapsulation?

653


What is abstraction and encapsulation?

568


write a C++ program for booking using constructor and destructor.

2042


What is the real time example of encapsulation?

590


What is the example of polymorphism?

554


Why polymorphism is used in oops?

579