3.5*6 Out[2]: 21.0 type(3.5) Out[3]: float 3.5*"hello" Traceback (most recent call last): File "/Users/ola/Library/Enthought/Canopy_64bit/User/lib/python2.7/site-packages/IPython/core/interactiveshell.py", line 2883, in run_code exec(code_obj, self.user_global_ns, self.user_ns) File "", line 1, in 3.5*"hello" TypeError: can't multiply sequence by non-int of type 'float' "hello"*3.5 Traceback (most recent call last): File "/Users/ola/Library/Enthought/Canopy_64bit/User/lib/python2.7/site-packages/IPython/core/interactiveshell.py", line 2883, in run_code exec(code_obj, self.user_global_ns, self.user_ns) File "", line 1, in "hello"*3.5 TypeError: can't multiply sequence by non-int of type 'float' "hello"*3 Out[6]: 'hellohellohello' 3.5.is_integer() Out[7]: False 3.is_integer() File "", line 1 3.is_integer() ^ SyntaxError: invalid syntax 3.0.is_integer() Out[9]: True 3==3 Out[10]: True 3==4 Out[11]: False 3 != 4 Out[12]: True 3 < 5 Out[13]: True "hello".upper() Out[14]: 'HELLO' len("hello") Out[15]: 5 hello[0:4] Traceback (most recent call last): File "/Users/ola/Library/Enthought/Canopy_64bit/User/lib/python2.7/site-packages/IPython/core/interactiveshell.py", line 2883, in run_code exec(code_obj, self.user_global_ns, self.user_ns) File "", line 1, in hello[0:4] NameError: name 'hello' is not defined "hello"[0:4] Out[17]: 'hell' "hello world"[3:6] Out[18]: 'lo ' "hello"[0] Out[19]: 'h' "hello"[4] Out[20]: 'o' type(3 > 5) Out[21]: bool 3 > 5 Out[22]: False