📜  is and as in c# 代码示例

📅  最后修改于: 2022-03-11 14:49:21.810000             🧑  作者: Mango

代码示例1
The is operator returns true if the given object is of the same type, whereas the as operator returns the object when they are compatible with the given type. The is operator returns false if the given object is not of the same type, whereas the as operator returns null if the conversion is not possible.