Question: This code is occasionally throwing a null pointer exception (NPE). How can you change the code so it never throws as NPE?

  1. Replace `!!.` with `?.`
  2. Replace `!!.` with `?:.`
  3. Surround the line with a try/catch block.
  4. Replace `!!.` with `?.let`.

Answer: The correct answer of the above question is Option A:Replace `!!.` with `?.`