/*
\n:回车
\t:制表符
\b:退格
\r:按下回车键转译字符,对 \ 后面的字符进行编译
\:
乘法口诀
*/
class ifDemo
{
public static void main(String[] args)
{
for(int x=1;x<=9;x++)
{
for(int y =1;y<=x;y++)
{
System.out.print(y + "*" + x + "=" + y*x + " ");
}
System.out.print("\n");
System.out.println("\"hello word\"");
}
}
}
//编译一个 倒三角的 等腰 星号
class ifDemo
{
public static void main(String[] args)
{
for(int x=1;x<=4;x++)
{
for(int y=1; y<=x;y++)
{
System.out.print(" ");
}
for(int z=x; z<=4; z++)
{
System.out.print("*" + " ");
}
System.out.print("\n");
}
}
}