Tell me applications of linked lists and mostly used linked list?
Submitted by: AdministratorUsed mainly to represent elements in a dynamic environment where it is added on an ad-hoc basis.
Especially in the cases where the total number of elements in the list cannot be pre-decided, linked lists are used. This does not lead to space insufficiency or space wastage as in case of arrays.
For eg. The no. of terms in a order-n polynomial varies greatly, using an array to store the co-efficients is an inefficient methods. If the array size is declared 100, a quadratic equation will use just 3 index and the rest 99 will be wasted. While for a sine or cosine series (from x to infinity) an overflow error might occur..!
Submitted by: Administrator
Especially in the cases where the total number of elements in the list cannot be pre-decided, linked lists are used. This does not lead to space insufficiency or space wastage as in case of arrays.
For eg. The no. of terms in a order-n polynomial varies greatly, using an array to store the co-efficients is an inefficient methods. If the array size is declared 100, a quadratic equation will use just 3 index and the rest 99 will be wasted. While for a sine or cosine series (from x to infinity) an overflow error might occur..!
Submitted by: Administrator
Read Online OS Data Structures Job Interview Questions And Answers
Top OS Data Structures Questions
☺ | Explain real world example of polymorphism and encapsulation? |
☺ | What is AVL tree? |
☺ | Why enum can not be used directly with printf function? |
☺ | What is a complexity of linear search, binery search? |
☺ | What is difference between the run time polymorphism and compile time poly morphism and about virtual function? |
Top Operating System (OS) Categories
☺ | RTOS Interview Questions. |
☺ | Windows 7 Interview Questions. |
☺ | MAC Operating System Interview Questions. |
☺ | Disk Operating System (DOS) Interview Questions. |
☺ | Shell Scripting Interview Questions. |