6 years ago in Introduction To Java

Which one of the following will declare an array and initialize it with five numbers?

[A] Array a = new Array(5);
[B] int [] a = {23,22,21,20,19};
[C] int a [] = new int[5];
[D] int [5] array;
Loading...
Next Question

Overall Stats

Attempted 304
Correct 107
Incorrect 82
Viewed 115

Answers

Guest
Guest
chaimaa elgotbi
chaimaa elgotbi - 1 week ago

chaimaa elgotbi from Casablanca, Morocco is saying int a [] = new int[5]; is correct answer

saliha rchid
saliha rchid - 1 week ago

saliha rchid from Casablanca, Morocco is saying Array a = new Array(5); is correct answer

Udith Liyanage
Udith Liyanage - 2 months ago

Udith Liyanage from Kandy, Sri Lanka is saying int [5] array; is correct answer

Bharath
Bharath - 3 months ago

Bharath from Hyderabad, India is saying int [] a = {23,22,21,20,19}; is correct answer

Renuka Siriwardhana
Renuka Siriwardhana - 4 months ago

Renuka Siriwardhana from Colombo, Sri Lanka is saying int a [] = new int[5]; is correct answer

Related Questions

process of writing the state of object into byte stream

  • [A] Deserialisation
  • [B] Externlisation
  • [C] serialisation
  • [D] print

The old name of Java was ?

  • [A] J language
  • [B] oak
  • [C] oct
  • [D] None of above

What is HotJava ?



  • [A] system software
  • [B] web browser
  • [C] java environment
  • [D] IDE

instance variable declare in

  • [A] class
  • [B] constructor

Which container use border layout

  • [A] Fram
  • [B] Dialog
  • [C] window
  • [D] ALL