Math, asked by anusreerajan66, 6 months ago


write a
program to input an array
numbers and

of
10 numbers and
display it​

Answers

Answered by pranshuagarwal48
0

Step-by-step explanation:

PLEASE MARK ME AS BRAINLIST.

Answered by mithulpranav24826
2

Answer:

import java.io.*;

class array

{

   public static void main(String [] args ) throws IOException

   {

       InputStreamReader isr = new InputStreamReader (System.in);

       BufferedReader br = new BufferedReader (isr);

       System.out.println("Enter 10 numbers for array");

       int a[] = new int [10]; // to reserve  memory

       // input to array

       for(int i=0;i<10;i++)

       {

           a[i] = Integer.parseInt ( br.readLine());

       }

       System.out.println("Content of the array");

       // output

       for(int i=0;i<10;i++)

       {

           System.out.println(a[i]);

       }

   }

}

Answered by M.Mithul Pranav

Hope it helps.

Similar questions