
Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Why is NullPointerException in Java
NullPointerException is a runtime exception and it is thrown when the application try to use an object reference which has a null value.
For example, using a method on a null reference.
Object ref = null; ref.toString(); // this will throw a NullPointerException
Advertisements