late 15c., "band attached to a letter with seals dangling on the free end," from French queue "a tail," from Old French cue, coe "tail" (12c., also "penis"), from Latin coda (dialectal variant or alternative form of cauda) "tail" (see coda). Also in literal use in 16c. English, "tail of a beast," especially in heraldry. The Middle English metaphoric extension to "line of dancers" (c. 1500) led to extended sense of "line of people, etc." (1837). Also used 18c. in sense of "braid of hair hanging down behind" (first attested 1748).