Initially, just press the number that you need to add to the falling number to make 10 i.e. if you see a 6, press 4. This is called a number bond (I think). Once you get the hang of it the wizard hat appears as your 'ship' - use the arrow keys to move it left and right; now when you press a number a bullet is fired and kill the falling number if you pressed the right number bond.
I made it in old Scratch. The costumes for the falling numbers are from somewhere else but I can't remember where.