Akshay Dave Thank you for your response.

!! is to tell the compiler that I am sure the value of the variable is not null, and if it is null throw a null pointer exception (NPE) where as ?. is to tell the compiler that I am not sure if the value of the variable is null or not, if it is null do not throw any null pointer exception and if it is not null please perform the operation.

Also, there is no difference in KotlinNullPointer and regular NullPointer.

A null pointer is basically any variable (reference) or pointer which is pointing to null.

Hope this helps. :)

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store