Tested the use of instanceof.