I wrote the following code from Head FIrst
java book..
and i got this error saying..
Exception in
thread "main" java.lang.NullPointerException
at Puzzle4.main(Puzzle4.java:18)
..which is at the line 18 : result = result + obs[x].doStuff(x);
Please tell me whats wrong?
---------------------------------------------------------------------------
----------------------------------------------------------