Update kdTree.java

Added a constructor
Changed flow in put() to dismiss nullexceptions