Program - Print row of 5 even numbers, 5 rows, last num 50
Hi guys, I'm new to Java and have an AP comp sci class. I have an assignment to use "for" loops to complete a goal.
We're just on the basics right now so please try to show me the simplest way of how I'm supposed to put this program together.
Basically, it needs to print out 5 rows of even numbers. The result has to be like this:
2 4 6 8 10
12 14 16 18 20
22 24 26 28 30
32 34 36 38 40
42 44 46 48 50
Edit: It needs to use for loops and they can be nested.
I know it's probably an easy logic to think of, but my brain is functioning properly and I've tried a 100 different combinations of for loops that didn't' work. And that has made me really frustrated that I can't figure out this simple looking problem.
I would really appreciate if you guys could help me solve this.