I managed to fix the problem. I just had it keep generating a random number between 1 and 100 until it got a successful insertion. However, on the merged list, if it found a duplicate I'd just have...
Type: Posts; User: orbin
I managed to fix the problem. I just had it keep generating a random number between 1 and 100 until it got a successful insertion. However, on the merged list, if it found a duplicate I'd just have...
I solved the problem by adding an else method and it does work now. However, I keep running into more problems! I need to generate two lists of 10 DataElements each, and none of the numbers can be...
I noticed after a bit of tinkering with the code that it always gets a true on the first insertUnique run through, but the second time it runs through it stalls.
public int...
Thank you for your help. It helped me rethink the problem. I managed to figure out a lot since the other day. However, now I'm having trouble insert a UNIQUE number into a list. I made two methods,...
I tried to read it like that but I think I'm over complicating my program. I updated my code, but still stuck on 3b case.
public boolean insert(DataElement insertItem){
...
We are supposed to write an insert method for an ordered link list. I'm working on the method and have most of it written in my OrderedLL class. However, I can't seem to understand how to deal with...