LoginSignup
0
0

More than 1 year has passed since last update.

二重for文② 九九表

Last updated at Posted at 2022-06-15

実行結果

スクリーンショット 2022-06-16 5.43.19.png

コード

public class Main {
	public static void main(String[] args) {
		for(int i=1; i<=9; i++) {
			for(int j=1; j<=9; j++) {
                System.out.printf("%d*%d=%-4d",i,j,i*j);
                //Sysyem.out.printf(書式, 引数1, 引数2, ....)
            }
            System.out.println("");   
        }
    }
}
0
0
2

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0