Advertisement
veronikaaa86

02. Multiplication Table

Aug 6th, 2022
737
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. package nestedLoops;
  2.  
  3. public class P02MultiplicationTable {
  4.     public static void main(String[] args) {
  5.  
  6.         for (int first = 1; first <= 10; first++) {
  7.             for (int second = 1; second <= 10; second++) {
  8.                 int product = first * second;
  9.                 System.out.printf("%d * %d = %d%n", first, second, product);
  10.             }
  11.         }
  12.     }
  13. }
  14.  
Advertisement
RAW Paste Data Copied
Advertisement