Study/숙제

구구단

나나83 2009. 11. 6. 20:21

class test
{
 public static void main(String[] args)
 {
   

   for(int i = 1 ; i <= 9 ; i+=3)
   {
    for(int j = 1 ; j <=9 ; j++)
    {
     for(int k =0; k < 3 ; k++)
     {
      System.out.print((i+k) + "*" + j + "=" + (i+k)*j + "\t");
     }
     System.out.println();
    }
    System.out.println();
   }
 }
}

'Study > 숙제' 카테고리의 다른 글

야구 게임  (0) 2011.05.09
다이아몬드 찍기  (0) 2011.05.09
if문으로 바꾸기  (0) 2009.11.05
수를 받아서 5 * 4* 3* 2* 1 = 결과가 나오겠금  (0) 2009.11.05
구구단  (0) 2009.11.05