+ 1
Question about C#
which operator determines whether an object is an instance of the given type in C sharp
2 Respostas
+ 1
If your are talking about just operators it should be the "is"-operator.
if (spot is Dog)
To do type checking you also can use GetType() together with Typeof()
if (spot.GetType() == typeof(Dog))
https://code.sololearn.com/cqT0PDpCtkhm
https://stackoverflow.com/questions/983030/type-checking-typeof-gettype-or-is