Computer Science, asked by misurseegayathom, 1 year ago

Program for Printing the Square of all Numbers from 1 to 10
Write a program to print the square of all numbers from 1 to 10.

Answers

Answered by NEECO
0
#include<iostream.h>void main(){for(int i=1;i<11;i++)cout<<i*i<<"/n";}

(C++)
Answered by crpiyushbansal
0

Answer:

package com.company;

public class square_10 {

   public static void main(String[] args) {

       int square;

       for(int i=1; i<=10; i++){

           square= i*i;

           System.out.print(square+" ");

       }

   }

}

Explanation:

Similar questions