Slide 13
Slide 13 text
Basic concepts - Methods/Operators
● and, or, not (Boolean)
● <, <=, >, >=, ==, !=, is, is not (Comparisons)
● +, -, *, /, //, %, -x, +x, ** (Numerical)
● abs, int, float, complex, divmod, pow (Numerical)
● in, not in, +, *, s[i], s[i:j], s[i:j:k] (Sequences)
● len, min, max s.index, s.count (Sequences)
● |, ^, &, <<, >>, ~ (Bitwise)
● Large number of string methods: s.upper(), s.lower(), s.endswith
(...), s.startswith(...), s.strip(), s.replace(...)
● Print to standard output: print('Hello world')
● Read input: input("What's your name?")
● Comprehensions: [key for key in data]