How to compare variables of two types without type conversion or type casting using if statement

Please see this.