📅  最后修改于: 2022-03-11 15:01:23.335000             🧑  作者: Mango
class Square
{
public static void main(String args[])
{
int i,sq=0; //Variable i and sq are declared
for(i=1;i<=10;i++) //for loop execution takes place
{
sq=i*i;
System.out.println("Square of"+i+"="+sq);//Prints the value stored in the variable i and sq.
}
}
}