Question: C ONLY PLEASE Write a program that stores multiplication tables from 1 to 9 in a 2-dimensional array. You should not use scanf to enter

C ONLY PLEASE

Write a program that stores multiplication tables from 1 to 9 in a 2-dimensional array. You should not use scanf to enter the values - each element of the 2D array must be assigned the appropriate value (using assignment statements). It then prompts the user to enter a choice. The choice must be a number between 0 and 9. If the user enters any other number, then the program prints a message saying that it is an invalid number.

If choice entered is 0, the program displays the multiplication tables from 1 to 9 as shown in the sample output below. The output must be exactly as shown below. The line of stars has 80 stars (*) in it. You may use \t (for tab) and (for newline) to get the correct spacing in the output.

If the choice entered is a number between 1 and 9 (both inclusive), the program must print the muliplication table for that number as shown in the sample input/output below.

Your program must repeat this as long as the user wishes to continue. Please follow the sample input/output for further clarification.

Sample Input/ output:

Enter zero (0) to see all multiplication tables from 1 - 9 OR

Enter a specific number between 1 and 9 to see its multiplication table

Enter a choice: 2

Printing multiplication table for 2:

-----------------------------------

2 X 1 = 2

2 X 2 = 4

2 X 3 = 6

2 X 4 = 8

2 X 5 = 10

2 X 6 = 12

2 X 7 = 14

2 X 8 = 16

2 X 9 = 18

Do you wish to continue? Enter y for yes, any othr character for no: y

Enter zero (0) to see all multiplication tables from 1 - 9 OR

Enter a specific number between 1 and 9 to see its multiplcation table

Enter a choice: 0

C ONLY PLEASE Write a program that stores multiplication tables from 1

Printing Multiplication Tables 1 - 9 One Two Three Four FiveSix Seven Eight Nine 2 5 10 15 20 25 30 35 40 1 2 One Two Three3 Four Five SIX Seven Eight 8 Nine 12 18 24 30 36 18 27 36 45 54 63 72 81 14 21 28 35 16 12 16 20 12 15 18 21 24 27 32 10 12 14 16 18 28 32 36 56 64 72 56 63 54 Do you wish to continue? Enter y for yes, any other character for no: n Good Bye

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!