The next-in-line effect is the phenomenon of people being unable to recall information concerning events immediately preceding their turn to perform. It may explain why people often forget names of people right after being introduced. – WTF Fun Facts
Source: https://en.wikipedia.org/wiki/Next-in-line_effect