The Student Room Logo
This thread is closed

Cambridge Chat (previously New Cambridge Students Entry 2004)

Willa
try discovering why running a procedure on a full list produces different results to running a procedure on half the list and then finishing the list and running the procedure again, when the only thing the procedure does is delete duplicates from the list!

Dude, what are you on about?
Reply 18321
Camford
Dude, what are you on about?


you're not the only one who is wrestling with java at this very moment you know!
Willa
you're not the only one who is wrestling with java at this very moment you know!

I didn't say I was. I merely stated that fact that I suck at Java and need help. I'm even confused about private and public matters at this moment.
Reply 18323
Camford
I didn't say I was. I merely stated that fact that I suck at Java and need help. I'm even confused about private and public matters at this moment.


awww poor you! The API and Java tutorial are your friends!
Willa
awww poor you! The API and Java tutorial are your friends!

can't be arsed to read the api... too confusing. Arthur Norman's specification for this thing isn't helping much either. I guess I'll have to leave the difficult part till after the term starts.
Nooooo - so many posts to read and no time to do it in. DAMMIT.

I'm not that sad - I'll just not read the posts. :smile:
Steveee
Nooooo - so many posts to read and no time to do it in. DAMMIT.

I'm not that sad - I'll just not read the posts. :smile:

There aren't that many funny posts being made recently.

Sorry to hear about your rejection. Good luck with Bristol though. It's a better city than Cambridge in many ways.
Reply 18327
the API is the bible of Java....it makes everything so easy to understand. And for the REALLY basic things, just use the Java Tutorial. Like understanding public and private and how they limit access etc!
Camford
There aren't that many funny posts being made recently.


Yeah, considering you seem to be talking about Java.

Pascal all the way! (AS Computing is not worthy of a single UCAS point)
Reply 18329
Willa
try discovering why running a procedure on a full list produces different results to running a procedure on half the list and then finishing the list and running the procedure again, when the only thing the procedure does is delete duplicates from the list!

Okay, just to check:

1. Have half the list.
2. Run procedure on half the list.
3. Populate second half of list.
4. Run procedure on entire list.
5. Result differs?

Seems like the problem is most likely to be that you need to be definitely running it the second time on the entire list. Is there any particular reason why you'd want it to run the duplicate removal multiple times, is space really an issue?

Incidentally, how are you removing duplicates?

A.
Willa
the API is the bible of Java....it makes everything so easy to understand. And for the REALLY basic things, just use the Java Tutorial. Like understanding public and private and how they limit access etc!

That's not the part I'm worrying about... it's the "not understanding part of the specification" bit I'm worrying about. I can do quite a bit of this thing, construct necessary classes, doing about 25% of the gui... There's the JPanel's paintComponent, which I've no idea about. There's something about a custom class called Document and a method used to associate a JPanel (or its subclass) with an instance of Document which I also have no idea about. other than that. It's cool.


Actually... nothing for me is "cool" with this piece of work.
Reply 18331
Alaric
Okay, just to check:

1. Have half the list.
2. Run procedure on half the list.
3. Populate second half of list.
4. Run procedure on entire list.
5. Result differs?

Seems like the problem is most likely to be that you need to be definitely running it the second time on the entire list. Is there any particular reason why you'd want it to run the duplicate removal multiple times, is space really an issue?

Incidentally, how are you removing duplicates?

A.



i found the problem in the end. When a duplicate was removed from the list, the indices were automatically decreased by 1 for all following items. However the procedure was using a for loop to go through the items, and so this meant it was skipping an item each time there was a removal of a duplicate. So I just added an "i--" into the code.
why am i awake?
naelse
why am i awake?

Sympathy insomnia - kinda like sympathy pains only it keeps you awake rather than hurting :smile:

My advice: head down, brace yourself, run into a wall really hard. Sweet :cool:

ZarathustraX
How do you say "mr incredible" in French? It seems to me to be one of the funniest sound on earth. :redface:
I should either go to bed, or drink large quantities of hot coffee... Not sleeping is not good me... 12 hours to go till dark :frown:. I need to get rid of my beard.
Lauren
you haven't been to sleep yet? oh dear. I've been to sleep and got up and now I'm in work.

I got up at 4pm yesterday... I'm taking this opportunity to adjust my biological clock. I was hoping to get some work done today. But I'm afraid I will only be fit enough to produce garbage for the garbage collector today :frown:...
Writing too many posts on one page of this thread isn't a good thing. But someone has to keep this place active.
Camford
How do you say "mr incredible" in French? It seems to me to be one of the funniest sound on earth. :redface:

Monsieur Incredabla
darkenergy
Monsieur Incredabla

em... doesn't seem to sound like what I heard... /me goes off to watch the film again.

Latest