Question: please i really need help figuring this out !! 2. Given two sorted lists, L1 and L2, complete a following procedure in Java to compute:

 please i really need help figuring this out !! 2. Given

please i really need help figuring this out !!

2. Given two sorted lists, L1 and L2, complete a following procedure in Java to compute: (a) L1L2 { x 1 x L1 and X L2 } using only the basic list operators (next), hasNext(), and compareTo)) and one loop public static AnyType extends comparable? super AnyType void difference(List L1, List iterL1- L1 . 1istlterator(); List Iterator iterL2 = L2.1istIterator(); if (iterL1.hasNext) && iterL2.hasNext) itemL1 iterL1.next; itemL2 iterL2.next); YOUR CODE GOES HER (b) L1 n L2xIxe L1 and xe L2 using only the basic list operators (next(), hasNext), and compareToO) and one loop public static AnyType extends Comparable super AnyType>> void intersection(List L2, List iterL1 L1 . list!terator(); ListIterator iterL2 = L2.1istlterator(); if ( iterL1.hasNext) && iterL2.hasNext) itemL1 iterL1.next) itemL2 iterL2.next); IYOUR CODE GOES HERE

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!