This is a silly question, but you can use this code to check if something is a particular type...
if (child is IContainer) { //....
Is ther
The is operator evaluates to a boolean result, so you can do anything you would otherwise be able to do on a bool. To negate it use the ! operator. Why would you want to have a different operator just for this?
is
!