subject

Two different implementations of the list adt: arraylist and lllist. for each of the following applications, decide which list implementation would be better for that particular application. you should consider both time efficiency and space efficiency, and you should assume that both implementations have an associated iterator like the lllistiterator that we discussed in lecture. explain your answers.

you need to store information about the gardening tools that you sell in your online store. to do so, you maintain a list of product records, each of which contains information about a single type of product, including how many copies of it you have in stock. you don’t tend to change the types of tools that you sell, and thus items are seldom added or removed from the list. however, you need to update a product’s record whenever your inventory of that product changes (e. g., because someone purchases a product’s position in the list is also its product id, and therefore updating a record involves using the product id to get the corresponding record and modifying its contents.

you need to maintain a list of tweets that are made by government officials in the current week. the number of tweets can vary widely from week to week in a way that is hard to predict. you start with an empty list at the start of the week, and as tweets are made you add them to the list. you need to frequently display the tweets in reverse chronological order – from most recent to least recent.

you are responsible for maintaining a monthly list of events for an online arts calendar. the number of events is fairly consistent from month to month. events are added to the list in chronological order, and you need to display them in that same order.

ansver
Answers: 1

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 13:30
Use the keyword strategy to remember the meaning of the following word. the meaning for the word has been provided. write your keyword and describe the picture you would create in your mind. centurion: a commander in the army of ancient rome. keyword: picture:
Answers: 2
question
Computers and Technology, 23.06.2019 15:30
1. ask the user how many questions are in the quiz. 2. ask the user to enter the key (that is, the correct answers). there should be one answer for each question in the quiz, and each answer should be an integer. e.g., 34 7 13 100 81 3 9 10 321 12 might be the key for a 10-question quiz. you will need to store the key in an array. 3. ask the user to enter the answers for the quiz to be graded. there needs to be one answer for each question. note that these answers do not need to be stored; each answer can simply be compared to the key as it is entered. 4. when the user has entered all of the answers to be graded, print the number correct and the percent correct. 5. add a loop so that the user can grade any number of quizzes with a single key. after the results have been printed for each quiz, ask "grade another quiz? (y/n)." note: you only have one array (the key). you are not creating a new key for each set of quiz answers.
Answers: 3
question
Computers and Technology, 23.06.2019 22:00
Jackson, who works in the finance department of a company, is holding a seminar for other employees on how to file taxes. only three employees sign up to attend the seminar. which device can he use to share his presentation with a group of three employees?
Answers: 1
question
Computers and Technology, 24.06.2019 06:30
Me and category do i put them in because this is science
Answers: 1
You know the right answer?
Two different implementations of the list adt: arraylist and lllist. for each of the following appl...
Questions
question
Mathematics, 20.01.2020 06:31
question
Mathematics, 20.01.2020 06:31
question
Mathematics, 20.01.2020 06:31
question
Mathematics, 20.01.2020 06:31
question
Mathematics, 20.01.2020 06:31
question
Business, 20.01.2020 06:31