What is null in c#, java?

后端 未结 9 1195
挽巷
挽巷 2020-12-15 23:09

Like... is it 0 like in C++? Or is it some \"special\" object? Or maybe something totally different?

-- EDIT --

I do know what it is, the

9条回答
  •  暖寄归人
    2020-12-15 23:48

    null is a "reference" to nothing, so it points to literally nothing.

    Additional info: A C# reference type can point to null (i.e.: nothing), a value type like int cannot point to null, although a valuetype can be used in the Nullable generic reference type.

提交回复
热议问题