Help - graphics in a game program

I have a student working on a game program in which he wants to model
balls bouncing off one another in a realistic way.  It has been 25 years
since my last Physics class and I was hoping someone could provide a
primer of some kind.

He has the x,y position of both balls and both velocity vectors.  As
output, he wants both velocity vectors after the collision.  I have been
thinking about how to model this based on conservation of momentum, but
haven't been able to work through the details.

He is using TP 7 in Win 95 DOS.

Thanks in advance.