Why would a guy sometimes act shy and othertimes arrogant around a girl?

He is usually very down to earth, talkative and sociable with everyone else but with me he is sometimes tense and othertimes he talks to me slightly condesending like I'm a silly little girl that is not worth his time even though I'm definitely not dumber than him.

Other people have pointed out that he avoids talking to me. When he is talking to me he seems withdrawn, he looks around the room like I am the most boring person in the world but for some reason he still inquires about my office hours. In group settings he looks at everyone except me.

I never pestered him and he is usually very friendly so why does he act like this? We never had any conflict and I get along with his friends just fine.

Why would a guy sometimes act shy and othertimes arrogant around a girl?
Post Opinion