Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

C FIFO Queue

Name: Anonymous 2009-01-03 19:11

I was looking up info on implementing a FIFO queue in C and came across this code from a published book: http://www.cs.sunysb.edu/~skiena/392/programs/queue.c

Isn't this thing going to fail after you've queued QUEUESIZE times, regardless of dequeuing?

Name: Anonymous 2009-01-03 19:13

q->last = (q->last+1) % QUEUESIZE;

Name: Anonymous 2009-01-03 19:27

QUEUESIZE
A fixed-size queue? Terrible!

And I could never figure out how to pronounce that word. It always ends up coming out as "kwaywee" or something similarly absurd.

Name: Anonymous 2009-01-03 19:27

So I guess the mod is causing it to wrap around to the beginning everytime it maxes out at QUEUESIZE? Wasn't immediately obvious to me

Name: Anonymous 2009-01-03 19:37

>>3
Queue is pronounced Q (cue || kyoo).

Also, how would you implement at FIFO queue? Got any standard algorithms you could recommend?

Name: Anonymous 2009-01-03 19:48

In LISP this would take me for seconds

Name: Anonymous 2009-01-03 20:00

In LISP this would take me call/cc seconds

Name: Anonymous 2009-01-03 20:19

In LISP this would take me c-c-c-combo breaker

Name: Anonymous 2009-01-03 21:49

>>5
Incorrect; its actually pronounced qwayway.

Name: Anonymous 2009-01-03 21:57

>>9
kwiwi

Name: Anonymous 2009-01-03 22:02

kyew

Name: Anonymous 2009-01-04 11:46

no, it sounds just like the letter Q. For example, "Johnny Dumbass needs to go back to school, and when he got there, he entered the QUEUE of people waiting to register."

Name: Anonymous 2009-01-04 12:51

>>12 see >>11

Name: Anonymous 2009-01-04 18:12

It's pronounced KAH WAH WE.
Much like "kawaii", but with an additional 'w'.

Name: Anonymous 2009-01-04 18:26

How do you pronounce ``deque''?

1) Deck
2) Deck-wee
3) De-cue (faggot)
4) Da-kway

Name: Anonymous 2009-01-04 18:51

duckw

Name: Anonymous 2009-01-04 18:56

>>15
You're doing it wrong. The correct pronunciation is supposed to have the ``(faggot)''.

Name: Anonymous 2009-01-04 20:43

ヂキュ

Name: Anonymous 2009-01-04 23:03

>>15
5) "GRUNNUR"

Name: Anonymous 2009-01-04 23:47

>>17
in this case the correct pronunciation includes the word faggot.

Name: Anonymous 2009-01-05 8:11

fah-got (faggot)

Name: Anonymous 2009-08-16 23:44

Lain.

Name: Anonymous 2009-08-17 0:11

Lain.

Name: Anonymous 2010-12-23 7:22

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List