Ask Question

9.2 code practice edhesive

+3
Answers (1)
  1. 19 May, 18:47
    0
    import java. util. Scanner;

    public class Main

    {

    public static void main (String[] args) {

    String NAME[] = new String[5];

    Scanner s1 = new Scanner (System. in);

    System. out. println ("Enter Array Elements (Names) ");

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

    {

    NAME[i] = s1. nextLine ();

    }

    System. out. println ("Array Elements (Names) ");

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

    {

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

    }

    }

    }

    Explanation:

    We need to write a program in java to explain the array declaration. And we have that program in the answer section.
Know the Answer?
Not Sure About the Answer?
Find an answer to your question 👍 “9.2 code practice edhesive ...” in 📗 Computers & Technology if the answers seem to be not correct or there’s no answer. Try a smart search to find answers to similar questions.
Search for Other Answers