can u please give a program that will control a keypad
We don't give out answers to homework/coursework problems here on the PF, lusy. We are willing to give you tutorial help, so that you can figure out the answers to your assignments yourself, however.
So here's a basic link to keypad info on wikipedia.org, with other links:
And you should also do some reading about how keyboards are scanned, and why there are diodes in the row/column arrangement of the key switch circuits. After you do that reading, it should be pretty apparent how to use a microcontroller (uC) to do the scanning.