Computers and Technology

A programmer has two lists of random words, list1 and list2. He has written a program that is intended to create a list, finalList, of all the words found in list1 and list2 in alphabetical order with no repeated words. His program makes use of the following procedures:Alphabetize(list)Returns a list that contains the elements of list in alphabetical order. Join (list 1, list2)Returns a list with the elements of list1 followed by the elements of list2RemoveDuplicates (list)Returns a list with the same elements in the same order as list, but with any duplicate elements removed. The programmer's program is as follows:list1 ← RemoveDuplicates (list1)list2 ← RemoveDuplicates (list2)finalList ← Join (list1, list 2)finalList ← Alphabetize (finalList)What will be the contents of finalList after running this program?finalList, will contain all the words found in list1 and list2 with no repeated words, but these may not be in alphabetical order. As intended, finalList, will contain all the words found in list1 and list2 in alphabetical order with no repeated words. finalList, will contain all the words found in list1 and list2 in alphabetical order, but it may contain repeated words. finalList, will contain all the words found in list1 and list2 but they may not be in alphabetical order and also contain repeated words.

answer
Answers: 2

Other questions on the subject: Computers and Technology

image
Computers and Technology, 22.06.2019 18:00, deathfire5866
Determine whether the following careers would require training or college.
Answers: 1
image
Computers and Technology, 23.06.2019 01:30, solikhalifeoy3j1r
In deadlock avoidance using banker’s algorithm, what would be the consequence(s) of: (i) a process declaring its maximum need as maximum possible for each resource. in other words, if a resource a has 5 instances, then each process declares its maximum need as 5. (ii) a process declaring its minimum needs as maximum needs. for example, a process may need 2-5 instances of resource a. but it declares its maximum need as 2.
Answers: 3
image
Computers and Technology, 23.06.2019 19:30, Felixthecat7186
Anul 2017 tocmai s-a încheiat, suntem trişti deoarece era număr prim, însă avem şi o veste bună, anul 2018 este produs de două numere prime, 2 şi 1009. dorel, un adevărat colecţionar de numere prime, şi-a pus întrebarea: “câte numere dintr-un interval [a, b] se pot scrie ca produs de două numere prime? “.
Answers: 3
image
Computers and Technology, 24.06.2019 00:00, Amrinderkhattra
Visualizing a game of “tag” to remember the meaning of contagious
Answers: 3
Do you know the correct answer?
A programmer has two lists of random words, list1 and list2. He has written a program that is intend...

Questions in other subjects:

Konu
Mathematics, 08.01.2021 05:50
Konu
Mathematics, 08.01.2021 05:50