C# Language Casting Checking compatibility without casting

Help us to keep this website almost Ad Free! It takes only 10 seconds of your time:
> Step 1: Go view our video on YouTube: EF Core Bulk Extensions
> Step 2: And Like the video. BONUS: You can also share it!

Example

If you need to know whether a value's type extends or implements a given type, but you don't want to actually cast it as that type, you can use the is operator.

if(value is int)
{
   Console.WriteLine(value + "is an int");
}


Got any C# Language Question?