Multiplication table

  • 6
  • Locked
In ancient times, when robots were few, human children were forced to learn the multiplication table. How cruel! Multiplication tables were written by hand over and over in notebooks. What a waste! We won't sully any paper, and there's no reason to teach you the table. Simply display it on the screen. Here's your secret weapon: the while loop.
You can't complete this task, because you're not signed in.
Comments (54)
  • Popular
  • New
  • Old
You must be signed in to leave a comment
Farhan Khan
Level 4 , United States
5 February, 18:54
Why does this exercise want us to use loop when we have not been taught loop yet? Can any CodeGym employee answer this question?
John Squirrels Website Admin at CodeGym
7 February, 08:44
The course may contain the tasks-from-the-future. If you do not have the idea how to solve it now, you can skip it and come back when you cover the lecture.
Elias Daniel Hung
Level 4 , Caracas
2 July 2021, 23:21
estuve tres días tratando de resolver este ejercicio
Elias Daniel Hung
Level 4 , Caracas
2 July 2021, 23:21
Hay que saber la diferencia entre = y == porque en el condicional if puede presentarse un error
Elias Daniel Hung
Level 4 , Caracas
2 July 2021, 23:19
yo utilicé dos ciclos for para eso investigué que eran esos ciclos, y algo que se llama algoritmo en Internet
Jomar Tayactac
Level 27 , Winnipeg, Canada
19 May 2021, 21:12
This task can be done without using a loop, your code will just be longer. If you'd like to use a loop but haven't learned it yet, simply google it.
Joe M
Level 41 , Owings Mills, United States
10 May 2021, 15:09
For loop is the way...as Mr. Parashar said. Put a "carriage return" in outside the inner "for" by doing "System.out.println("")" after the inner "for".
ROOPAK PARASHAR
Level 8 , New Delhi, India
25 April 2021, 06:34
apply loops. sol- use two for loop and you are done
Josh Werner
Level 3 , Granite City, United States
19 April 2021, 19:14
Why does the solution they give you work? (Please use small words and sock puppets).
Omr
Level 8 , Hutton Bushel, United Kingdom
27 March 2021, 14:35
I used a for loop to solve this problem
Erick De Santiago
Level 6 , Dallas, United States
14 January 2021, 01:18
I used all the concepts that we have learned so far. I created a method (multipleMatrix) which multiplied a given value 10X and printed the output. Then from my main method - I invoked my method 10 more times: multipleMatrix(1) multipleMatrix(2) etc. AND IT WORKED!!! Super pumped as it did take me a good 30-45 minutes to resolve (still a rookie) Reading through the comments, I do see different suggestions on how to solve this! Great ideas - hope mine makes sense and can help someone out :)
Usman Full Stack Developer at QA
23 June 2021, 16:10
nice one man :)