in an impromptu manner <sat down and wrote the ⋯ story off the top of his head ― Jerome Beatty, Jr.>
OFF THE TOP OF ONE'S HEAD
Meaning of OFF THE TOP OF ONE'S HEAD in English
Merriam Webster Collegiate English Dictionary. Merriam Webster - Энциклопедический словарь английского языка. 2012