if($A->b->c != null) //c exists
c does not exist, its value will be
null (or, to be more precise, it will have no value). Note, however, that for this to work, both
b need to not be
null. Otherwise, PHP will throw an error (I think).