i'm having trouble to program this!! SOS reply asap

Standard telephone keypads contain the digits 0 through 9. The numbers 2 through 9 each have three letters associated with them.

Many people find it difficult to memorize phone numbers, so they use the correspondence between digits and letters to develop eight-letter words that correspond to their phone numbers. For example, a person whose telephone number is 4263-7663 might use the correspondence in Table 1 to develop the eight-letter word “HANDSOME” so that people can easily remember his phone number. Each eight-letter word corresponds to exactly one eight-digit telephone number. A delivery service could surely do so with the number 3354-8379 (i.e. “DELIVERY”).

Each eight-digit phone number corresponds to many separate eight-letter words. Unfortunately, most of these represent unrecognizable juxtapositions of letters. It is possible, however, that the owner of a barber shop would be pleased to know that the shop’s telephone number, 4247-2888, corresponds to “HAIRCUTS”. A hospital with the phone number 4677-4825 would be pleased to know that the number corresponds to the letters “HOSPITAL”. A Bodyshop owner would be pleased to know that the shop’s number, 2639-7467, corresponds to “BODYSHOP”.

Write a program that, given an eight-digit number, writes to a file every possible eight-letter word combination corresponding to that number. There are 6561 (38) such words. Avoid phone numbers with the digits 0 and 1.

Digit Letters

2 A B C

3 D E F

4 G H I

5 J K L

6 M N O

7 P R S

8 T U V

9 W X Y

Table 1: Telephone keypad digits and letters.

i've tried many ways.. but it is b'cos i don't have enough knowledge...please help please...