what is the use of using linked list and array?
Answer Posted / vaishnavi varadarajan
Use of array: All the elements are lumped together in one
block of memory. Individual elements can be accessed thru
Array index. Random access & Dynamic allocation are
possible.
Use of Linked list: Linked list allocates space for each
element separately in its own block of memory called
a "linked list element" or "node". It gets the overall
structure by using pointers to connect all its nodes
together like the links in a chain. Here the elements of
list can be accessed thru memory address (Since the pointer
stores a reference to another variable)which improves the
efficiency. Size of the list can also be modified (ie) we
can insert/delete elements of the list.
Is This Answer Correct ? | 2 Yes | 1 No |
Post New Answer View All Answers
Explain how do you determine the length of a string value that was stored in a variable?
What is static and volatile in c?
What is the difference between formatted&unformatted i/o functions?
Explain what is the advantage of a random access file?
Why do we use & in c?
What is the scope of global variable in c?
Can you explain what keyboard debouncing is, and where and why we us it? please give some examples
write a program fibonacci series and palindrome program in c
Hi can anyone tell what is a start up code?
Sir,please help me out with the code of this question. Write an interactive C program that will encode or decode multiple lines of text. Store the encoded text within a data file, so that it can be retrieved and decoded at any time. The program should include the following features: (a) Enter text from the keyboard, encode the text and store the encoded text in a data file. (b) Retrieve the encoded text and display it in its encoded form. (c) Retrieve the encoded text, decode it and then display the decoded text. (d) End the computation. Test the program using several lines of text of your choice.
Write a program to generate the Fibinocci Series
What are the different types of C instructions?
Write a C program to help a HiFi’s Restaurant automate its breakfast billing system. Your assignment should implement the following items: a. Show the customer the different breakfast items offered by the HiFi’s Restaurant. b. Allow the customer to select more than one item from the menu. c. Calculate and print the bill to the customer. d. Produce a report to present your complete program and show more sample output. Assume that the HiFi’s Restaurant offers the following breakfast menu: Plain Egg $2.50 Bacon and Egg $3.45 Muffin $2.20 French Toast $2.95 Fruit Basket $3.45 Cereal $0.70 Coffee $1.50 Tea $1.80
Write a code to generate divisors of an integer?
What are valid operations on pointers?