java - Checking object of wrapper class Float is null -
i need check object of wrapper class null.for have written checking statements
float a=null; a==null; a.tostring().equals(null)
but these wrong.please advice me
a == null
right way it
attempting a.tostring().equals(null)
throw nullpointerexception
, because can not invoke method (in case tostring()
on null
object (the equals()
never executed)
Comments
Post a Comment