Homework for this weekend is TryItOut number 1 from chapter 8
You need to write a program that produces a times table of the user's choice.
get an input and store in a variable (as a string) -- call it "n"
use a for loop to loop "i" from 1 up to 10 (or 12):
each time, print a statement of "n" times "i" = (n*i)
it should LOOK very similar to, when the user picks 5:
Which multiplication table would you like?
5
Here's your table:
5 x 1 = 5
5 x 2 = 10
5 x 3 = 15
5 x 4 = 20
5 x 5 = 25
5 x 6 = 30
5 x 7 = 35
5 x 8 = 40
5 x 9 = 45
5 x 10 = 50
Good Luck!!!
No comments:
Post a Comment