/** javaのプログラム 練習7 x × y の表 */ import java.io.*; class s7t { public static void main (String[] args) throws IOException { BufferedReader in = new BufferedReader (new InputStreamReader(System.in)); /* */ int x,y,a,b,k; System.out.print("xは1からいくつまで? "); a = (new Integer(in.readLine())).intValue(); /* */ while ( a != 0 ) { System.out.print("yは1からいくつまで? "); b = (new Integer(in.readLine())).intValue(); /* */ for ( x = 1; x <= a ; x++ ) { for ( y = 1; y <= b ; y++ ) { k = x * y; System.out.print ( a ); } System.out.println(); } /* */ System.out.print("xは1からいくつまで? "); a = (new Integer(in.readLine())).intValue(); } System.out.print("実行終了"); } }