I went to school with a guy like that. He was a loser/total geek in high school but puberty was his friend so he got all egotistical. He would always try and say something to one up me and I never got the reason why.

I refrain from interacting with him at all costs. I just say "that's nice to know" and move on.