 The song sung during the riddle game which ends giving the answer  ("The answer is dark") is derived from one of the riddles Gollum  asks in the book. All the riddles asked are directly quoted from the  book, and there are five others not used.