how to check type of variable in python in if condition code example Example: check type of variable in python str = "Hello" type(str)