A cue is a signal or prompt — an actor waits for their cue — and also the stick used in snooker. A queue is a line of people waiting, and in computing a structure processed in order. The phrase is "on cue", not "on queue".
The core difference
A prompt and a line.
- cue — a signal: right on cue, take your cue from. Also a snooker cue.
- queue — a waiting line: join the queue, a print queue.
The spelling
Queue is famously the English word with the most silent letters — the "ueue" contributes nothing audible. It comes from French, ultimately from Latin cauda, tail, which is the image: people strung out behind one another.
The transatlantic note
British English says queue; American English generally says line for people, but uses queue in computing without hesitation. So "queue" is universal in tech and regional in daily life.