Yesterday I had a terrible experience in an interview.

Interviewer asked me about pure virtual function.
I said, It may or may not have definition in base class, but derived classes should provide definition unless they also want to be abstract class.

But interviewer kept on asking that "Can pure virtual have definition !!! ???"...
I said yes.

Again he said "Pure ?"

I said yes. It is allowed, derived classes can explicitly call that function if they want that particular behavior.

He sent me out.
I am sure that he doesn't know the fact that pure virtual function can have definition.

How to deal with this kind of Interviewers ?

After asking 2nd time, should i lie that it can't have definition ? :)

Or i should stick to my words and loose the job opportunity ?

No.  And you should thank your lucky stars that you got missed by that particular bullet.  Working for people who refuse to admit that they might not know everything, and refuse to learn from others, is a VERY unpleasant experience.