You are on page 1of 34

A crash course on python

Dr. Noman Islam


Installation
• Python 3.5
• Anaconda
• PyCharm
Indentation
• Python use identation instead of delimeters

• Whitespace is ignored inside parentheses and


brackets, which can be helpful for long-winded
computations
• You can also use a backslash to indicate that a
statement continues onto the next line
Modules
Defining functions
Lambda expression
Default arguments
Strings
Exceptions
List
Slicing list
Checking membership in list
Unpack list
Tuple
Dictionaries
Default dict
Counter
Set
Control flow
Truthiness
• Following are all false.
Sorting
List comprehension
Generators and iterators
Regular expressions
Object oriented programming
Functional tools
Map
Filter
Enumerate
zip
args and kwargs

You might also like