Answer to Question #285545 in Java | JSP | JSF for kkkkkk

Question #285545

for loop



sample output




c. Number Square Cube



1 1 1



2 4 8



3 9 27



4 16 64



5 25 125



.



.



.



10 100 1000




1
Expert's answer
2022-01-07T09:00:40-0500
public class Main {
    public static void main(String[] args) {
        for (int i = 1; i <= 10; i++) {
            System.out.print(i + " ");
            System.out.print(i * i + " ");
            System.out.print(i * i * i);
            System.out.println();
        }
    }
}

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be the first!

Leave a comment

LATEST TUTORIALS
New on Blog