How to set area boundary in catch game?

Hi there,
I have a catch game tutorial but the problem is that the catcher which is controlled by arrow keys on the keyboard slides out of the screen. How do I write the code in such a way that it will slide within a boundary?