โ Times table
Problem
Read a whole number n and print the first five lines of its times table, in the form "n x i = result".
You will learn: Use a for loop to produce formatted lines.
Examples
Input: 7
Output: 7 x 1 = 7 7 x 2 = 14 7 x 3 = 21 7 x 4 = 28 7 x 5 = 35
Hints
๐ก
โ Verified Submissions are checked against all tests, including hidden ones.
โถ Runs in your browser Run checks the example tests in your browser. Verified grading with hidden tests needs the secure runner, which is not set up yet โ submissions are saved as practice, with no score.
Not available yet Code execution for this language is not available yet: the secure code runner has not been set up. You can write and save your code and compare it with the worked solution, but it will not be run.
Loading editorโฆ
Example tests (ran in your browser)
-
Expected:
Got:
Printed output
Stuck? Read the failing case carefully, compare the expected and actual values, then try a hint. (AI debugging help is not configured on this server.)
Worked solution and explanation
Next challenge