A

Admin • 825.56K Points
Coach

Q. How to iterate through a String array using enhanced for loop?

  • (A) for (int i : array)
  • (B) for (String s : array)
  • (C) for (char c : array)
  • (D) for (Object o : array)

Explanation by: Admin
Use `for (String s : array)` to iterate over String array elements.

You must be Logged in to update hint/solution

Discusssion

Login to discuss.

Be the first to start discuss.