Multiple choice technology web technology

If I do not provide any arguments on the command line, then the String array of Main method will be?

  1. null

  2. empty

  3. cannot be determined

  4. None of the above

Reveal answer Fill a bubble to check yourself
B Correct answer
Explanation

When no command-line arguments are provided, Java passes an empty String array (length 0) to main(), not null. The array object exists but contains no elements, so args.length would be 0.