我在前面的博客中实现了C语言打印乘法口诀,博客地址http://blog.csdn.net/u010105970/article/details/18446365
Java打印乘法口诀代码
public class ChengfaDemo
{
public static void main(String [] args)
{
for(int i = 1; i <= 9; i++)
{
for(int j = 1; j <= i; j++)
{
System.out.print(j + "X" + i + "=" + i*j + "\t");
}
System.out.println();
}
}
}
执行结果: