Page 1 of 1

Question 3 You are given the following names Set 1 Riaan, Kabelo, Palesa, Thando. Marianne, Andile Set 2 = Charles, Pale

Posted: Fri Jul 08, 2022 6:38 am
by answerhappygod
Question 3 You Are Given The Following Names Set 1 Riaan Kabelo Palesa Thando Marianne Andile Set 2 Charles Pale 1
Question 3 You Are Given The Following Names Set 1 Riaan Kabelo Palesa Thando Marianne Andile Set 2 Charles Pale 1 (56.54 KiB) Viewed 53 times
Question 3 You are given the following names Set 1 Riaan, Kabelo, Palesa, Thando. Marianne, Andile Set 2 = Charles, Palesa, Tshifhiwa, Xolisa, Andries, Thando Write a Java program using NetBeans that will do the following: Add the above names into two priority queues. Print all the elements in both priority queues. Check which names in the first priority queue are also in the second priority queue, then add them to a third priority queue. Print out all the elements in the third priority queue. a. b. C. d. (15 Marks) Below is a screenshot of the expected program in operation:
Output - ITJVA2VAQn3 (run) x run: Elements in the First Priority Queue: [Andile, Marianne, Kabelo, Thando, Riaan, Palesa] Elements in the Second Priority Queue: [Andries, Charles, Thando, Xolisa, Palesa, Tshifhiwa] Elements in the Third Priority Queue: [Palesa, Thando] BUILD SUCCESSFUL (total time: 0 seconds) Figure 5 - Program Output Source: Makura S.M (2022). (20 Marks)