A

Admin • 828.70K Points
Coach

Q. Which of the following methods will remove all mappings from a Map?

  • (A) delete()
  • (B) removeAll()
  • (C) clear()
  • (D) reset()
  • Correct Answer - Option(C)
  • Views: 12
  • Filed under category Java
  • Hashtags: Java Map

Explanation by: Admin
The `clear()` method removes all key-value mappings from a Map.

You must be Logged in to update hint/solution

Discusssion

Login to discuss.

Be the first to start discuss.