keeping track of number of comparison

1 view
Skip to first unread message

Minh

unread,
Dec 5, 2010, 6:37:46 PM12/5/10
to COSC2320
In Section 4, it says
For the DELETE command... please keep track of the number of
comparison that you need to perform.
In the Output Syntax for DELETE, it doesn't have a number of
comparison output.
So where should I output that number?

Mohammed Alam

unread,
Dec 5, 2010, 6:49:10 PM12/5/10
to COSC2320
ANother question regarding that...

Where should i output the information of book not found??

ahmad qawasmeh

unread,
Dec 5, 2010, 7:09:31 PM12/5/10
to cosc...@googlegroups.com
Hi,
 
Everything should be printed out in the output text file. I mentioned that before.
 
Regards,
Ahmad

Josh

unread,
Dec 5, 2010, 8:39:53 PM12/5/10
to COSC2320
Can we get an answer to Minh's question? It is not in the output
example for DELETE in the homework description.

I asked the same question on Tuesday of last week and never got
answer. If we were supposed to do something with this, I think we
should have had answer long before now.



Thanks,

Josh

On Dec 5, 6:09 pm, ahmad qawasmeh <arqawas...@gmail.com> wrote:
> Hi,
>
> Everything should be printed out in the output text file. I mentioned that
> before.
>
> Regards,
> Ahmad
>

ahmad qawasmeh

unread,
Dec 5, 2010, 8:55:31 PM12/5/10
to cosc...@googlegroups.com
Hi,
 
As I mentioned, It is better to associate this number with the delete output syntax. Anyhow, it is not mandatory, but you need
to show it in your implementation. We will not ask about this number to be shown in the output. Don't worry.
 
Regards,
Ahmad

Lucas Hawk

unread,
Dec 5, 2010, 8:56:38 PM12/5/10
to cosc...@googlegroups.com
i dont know what that means.
 
This is what i will do - I will count the number of comparisons for delete, and output it to the command line. Will that work?
 
I apologize to the class, I am not trying to sign anyone else up for work, and implying they should do this, but i am just letting you know what i am doing, and hoping (this thing is due in 3 hours...) that it will fly...
 
Thanks
 
Luke

--
Rev. Lucas A Hawk
W Dallas Universal Church of Life
2210 W Dallas
Houston, TX 77019

TED SPRADLEY

unread,
Dec 5, 2010, 9:02:02 PM12/5/10
to cosc...@googlegroups.com
Thanks for bringing it back up.  I had put this so far on the back burner that I had forgotten about it and started drinking beer! (kidding, I'm not old enough to drink)

So, no output required.  How are you guys going to check it Ahmad?   I mean exactly where should we put the number of comparisons so you can check it?

Thanks, Ted

Joe

unread,
Dec 5, 2010, 9:02:34 PM12/5/10
to COSC2320
I do not understand what we are supposed to do.. I guess with 3 hours
left it is too late to figure it out

On Dec 5, 7:56 pm, Lucas Hawk <lukeh...@gmail.com> wrote:
> i dont know what that means.
>
> This is what i will do - I will count the number of comparisons for delete,
> and output it to the command line. Will that work?
>
> I apologize to the class, I am not trying to sign anyone else up for work,
> and implying they should do this, but i am just letting you know what i am
> doing, and hoping (this thing is due in 3 hours...) that it will fly...
>
> Thanks
>
> Luke
>
>
>
>
>
>
>
>
>
> On Sun, Dec 5, 2010 at 7:55 PM, ahmad qawasmeh <arqawas...@gmail.com> wrote:
> > Hi,
>
> > As I mentioned, It is better to associate this number with the delete
> > output syntax. Anyhow, it is not mandatory, but you need
> > to show it in your implementation. We will not ask about this number to be
> > shown in the output. Don't worry.
>
> > Regards,
> > Ahmad

ahmad qawasmeh

unread,
Dec 5, 2010, 9:02:42 PM12/5/10
to cosc...@googlegroups.com
Hi,
 
It is not mandatory to output the number of comparisons. You just need to show it in your implementation as mentioned in the HW description. Don't worry about the output. I am saying that to everybody. What I mean that when you find the bucket that has the specified book id, you will go through the linked list until you find this book and delete it.  
 
Regards,
Ahmad

Josh

unread,
Dec 5, 2010, 9:09:49 PM12/5/10
to COSC2320
So if your program can delete the book with matching ID from the
linked list stored in the hash table, that is all we need it to do to
keep track of the number of comparisons?

Or do you want to see that we have a variable with the number of
comparisons?

If we do print it out, would it be like this (if the book is the
second book in the linked list):
DELETED bucket 0: book id 200, 2 comparisons

Thanks,

Josh

On Dec 5, 8:02 pm, ahmad qawasmeh <arqawas...@gmail.com> wrote:
> Hi,
>
> It is not mandatory to output the number of comparisons. You just need to
> show it in your implementation as mentioned in the HW description. Don't
> worry about the output. I am saying that to everybody. What I mean that when
> you find the bucket that has the specified book id, you will go through the
> linked list until you find this book and delete it.
>
> Regards,
> Ahmad
>
> On Sun, Dec 5, 2010 at 8:56 PM, Lucas Hawk <lukeh...@gmail.com> wrote:
> > i dont know what that means.
>
> > This is what i will do - I will count the number of comparisons for delete,
> > and output it to the command line. Will that work?
>
> > I apologize to the class, I am not trying to sign anyone else up for work,
> > and implying they should do this, but i am just letting you know what i am
> > doing, and hoping (this thing is due in 3 hours...) that it will fly...
>
> > Thanks
>
> > Luke
>
> >   On Sun, Dec 5, 2010 at 7:55 PM, ahmad qawasmeh <arqawas...@gmail.com>wrote:
>
> >> Hi,
>
> >> As I mentioned, It is better to associate this number with the delete
> >> output syntax. Anyhow, it is not mandatory, but you need
> >> to show it in your implementation. We will not ask about this number to be
> >> shown in the output. Don't worry.
>
> >> Regards,
> >> Ahmad

ahmad qawasmeh

unread,
Dec 5, 2010, 9:10:36 PM12/5/10
to cosc...@googlegroups.com
Hi,
 
Don't worry. The main thing is to have a linked list for each bucket so you go through the books in that specific bucket in O(n) complexity in the worst case to find any book that needs to be deleted. I hope it is clear for everyone.
 
Regards,
Ahmad

Mario Blanco

unread,
Dec 5, 2010, 9:12:42 PM12/5/10
to COSC2320
If I already submitted my assignment should I go back and implement
this?

On Dec 5, 8:10 pm, ahmad qawasmeh <arqawas...@gmail.com> wrote:
> Hi,
>
> Don't worry. The main thing is to have a linked list for each bucket so you
> go through the books in that specific bucket in O(n) complexity in the worst
> case to find any book that needs to be deleted. I hope it is clear for
> everyone.
>
> Regards,
> Ahmad
>
> On Sun, Dec 5, 2010 at 9:02 PM, TED SPRADLEY <ted.sprad...@loansonline.us>wrote:
>
>
>
> > Thanks for bringing it back up.  I had put this so far on the back burner
> > that I had forgotten about it and started drinking beer! (kidding, I'm not
> > old enough to drink)
>
> > So, no output required.  How are you guys going to check it Ahmad?   I mean
> > exactly where should we put the number of comparisons so you can check it?
>
> > Thanks, Ted
>
> >  On Dec 5, 2010, at 7:56 PM, Lucas Hawk wrote:
>
> >  i dont know what that means.
>
> > This is what i will do - I will count the number of comparisons for delete,
> > and output it to the command line. Will that work?
>
> > I apologize to the class, I am not trying to sign anyone else up for work,
> > and implying they should do this, but i am just letting you know what i am
> > doing, and hoping (this thing is due in 3 hours...) that it will fly...
>
> > Thanks
>
> > Luke
>
> > On Sun, Dec 5, 2010 at 7:55 PM, ahmad qawasmeh <arqawas...@gmail.com>wrote:
>
> >> Hi,
>
> >> As I mentioned, It is better to associate this number with the delete
> >> output syntax. Anyhow, it is not mandatory, but you need
> >> to show it in your implementation. We will not ask about this number to be
> >> shown in the output. Don't worry.
>
> >> Regards,
> >> Ahmad

ahmad qawasmeh

unread,
Dec 5, 2010, 9:17:20 PM12/5/10
to cosc...@googlegroups.com
Hi,
 
Guys. I have mentioned it so many times. IT'S NOT MANDATORY TO PRINT OUT ANYTHING.  We don't want to have a new requirement in the assignment. The main thing is o show that you have a linked list for each bucket.
 
Regards,
Ahmad 

RC

unread,
Dec 5, 2010, 10:14:40 PM12/5/10
to COSC2320
Jesus Christ!
Couldn't y'all see what the TA had been saying! It's unnecessary
period

If anyone wants to do extra work, come clean up my messy assignment,
please.

Blake

unread,
Dec 5, 2010, 10:34:10 PM12/5/10
to COSC2320
It's getting to crunch time and I can tell I'm not the only one
stressed!
Good luck everybody!
By the way:
I have a counter that counts every iteration of the linked list until
the correct
node is found. But I don't output that variable.
Reply all
Reply to author
Forward
0 new messages