from __future__ import division, print_function # Python 3 a = 4 from sympy import S b = S(4) a b a/5 b/5 type(a) type(b) type(a/5) type(b/5) type(4) type(4.0) type(True) type('bonjour') type([3,4,5]) type((3,4,5)) type({2:3, 4:5}) 4 4 + 6 7 * 9 4 - 6 27 % 10 27 // 10 type(27 // 10) int() int(4) int(4.02) int('41234') type(2 ** 61) type(2 ** 62) type(2 ** 63) type(2 ** 64) 4. 4. * 3.41 type(_) 4. * 3 4 / 5 float() float(34) float('1234') float('1234.56') True False type(False) type(True) True or False False and True True and True True and False False and True False and False True or True True or False False or True False or False not True not False 13 == 5 + 8 20 > 34 bool(113) bool(0) bool(1) 'bonjour' "bonjour" "aujourd'hui" 'Je suis "ici"' """Je suis "ici" aujourd'hui""" str(12345) str(12345.789) w = 'bonjour' w[0] w[1] w[6] w[-1] w[2:5] w[:4]