Look at line 42, find the variable with the null value and then backtrack to find out why that variable doesn't have a valid value.Exception in thread "main" java.lang.NullPointerException
at inputintercase1.DataBase.toString(DataBase.java:42 ) (this is the line where iterator is created and initialized)
at inputintercase1.InputIntercase1.main(InputIntercas e1.java:135)
Please edit your post and wrap your code with
[code=java]
<YOUR CODE HERE>
[/code]
to get highlighting and preserve formatting.