We are here with you hands in hands to facilitate your learning & don't appreciate the idea of copying or replicating solutions. Read More>>
Study Groups By Subject code Wise (Click Below on your university link & Join Your Subject Group)
Looking For Something at vustudents.ning.com?Search Here
Graded Discussion Board (GDB) will be launched on Monday, January 29, 2018 and it will close on Tuesday, January 30, 2018.
Suppose you are working as a developer in a software house. A task is given to you to build an application for a shopping mall to maintain the inventory of different products. Products are divided into different categories. The number of categories are fixed but products in each category can increase/decrease depend on introducing new products. When new product will arrive it will be added to its category, if product will already in any category then only its quantity will update.
From array, singly linked list and doubly linked list, which data structure you will prefer to use to build required application. Searching of product should be efficient and application should take minimum possible memory. Select data one or more structure(s) of your choice with solid reason to justify your selection.
A concise, coherent and to the point answer is preferred over lengthy comment having irrelevant details. Answers, posted on regular Lesson's MDB or sent through email will NOT be considered in any case.
Please note GDB does not have any grace day. We are giving about a full week to prepare your comments and 48 hours to just post them. GDB comments will not be accepted through email in any case.
Best of Luck!
Share This With Friends......
Proper or sahi gdb share kar plz cs301
We can't use it. because it uses three pointers. Which makes the searches slow. It also uses more memory than singly linked list.
We use doubly only when their is no limitation of memory. But in the given scenario, we have to choose the method that uses the lowest memory.
So, singly is the best answer.
but efficient searching is also a requirement. and we can do it quickly if we do it in both directions. only in one direction will maybe lead to a dead end.
Right but when we use doubly, our second requirement will not be fulfilled. Because while dealing with doubly we are not able to use minimum memory. We have to look for both the requirements
full and final solution click here below link
GDB No #1
Singly linked list date structure I all prefer to use to build required application. Searching of product should be efficient and application should take minimum possible memory. Because
Singly linked list can mostly be used for stacks
bro its to much take time for searching
Bro. what's this... Please read the question carefully.
Linked lists have several advantages over arrays. Elements can be inserted into linked lists indefinitely, while an array will eventually either fill up or need to be resized, an expensive operation that may not even be possible if memory is fragmented. Similarly, an array from which many elements are removed may become wastefully empty or need to be made smaller.
On the other hand, arrays allow random access, while linked lists allow only sequential access to elements. Singly-linked lists, in fact, can only be traversed in one direction. This makes linked lists unsuitable for applications where it's useful to look up an element by its index quickly, such as heapsort. Sequential access on arrays is also faster than on linked lists on many machines due to locality of reference and data caches. Linked lists receive almost no benefit from the cache.
Another disadvantage of linked lists is the extra storage needed for references, which often makes them impractical for lists of small data items such as characters or boolean values. It can also be slow, and with a naïve allocator, wasteful, to allocate memory separately for each new element, a problem generally solved using memory pools.