Holding two keyboard buttons at ones

I can't see how print helps me to hold two buttons at once.
I also need to use keycodes and not ascii so that the keyboard can still work if I change to lowercase letters