- 1. Functional programmin in Python
- 2. Programming Paradigms
- 3. Functional programming
4. range
- 4.1. Iterators (Iterables)
- 4.2. range
- 4.3. range index and len
- 4.4. filehandle index and len
- 4.5. range with list
- 4.6. range vs. list size
5. map
- 5.1. for loop with transformation
- 5.2. map
- 5.3. map with list
- 5.4. size of map
- 5.5. map delaying function call
- 5.6. map on many values
- 5.7. double with lambda
- 5.8. What is lambda in Python?
- 5.9. lambda returning tuple
- 5.10. map returning tuples
- 5.11. lambda with two parameters
- 5.12. map for more than one iterable
- 5.13. map on uneven lists
- 5.14. replace None (for Python 2)
- 5.15. map on uneven lists - fixed (for Python 2)
- 5.16. map mixed iterators
- 5.17. map fetch value from dictionary
- 5.18. Exercise: string to length
- 5.19. Exercise: row to length
- 5.20. Exercise: compare rows
- 5.21. Solution: string to length
- 5.22. Solution: row to length
- 5.23. Solution: compare rows
6. Part 2
- 6.1. filter in a loop
- 6.2. filter
- 6.3. filter with lambda
- 6.4. filter - map example
- 6.5. filter - map in one expression
- 6.6. filter a dictionary using dict comprehension
- 6.7. Get indices of values
- 6.8. reduce
- 6.9. reduce empty list
- 6.10. reduce with default
- 6.11. reduce list of dictionaries
- 6.12. zip
- 6.13. Combining two lists using zip
- 6.14. Creating dictionary from two lists using zip
- 6.15. all, any
- 6.16. Compare elements of list with scalar
- 6.17. List comprehension - double
- 6.18. List comprehension - simple expression
- 6.19. List generator
- 6.20. List comprehension
- 6.21. Dict comprehension
- 6.22. Lookup table with lambda
- 6.23. Read lines without newlines
- 6.24. Read key-value pairs
- 6.25. Create index-to-value mapping in a dictionary based on a list of values
- 6.26. Exercise: min, max, factorial
- 6.27. Exercise: Prime numbers
- 6.28. Exercise: Many validator functions
- 6.29. Exercise: Calculator using lookup table
- 6.30. Exercise: parse file
- 6.31. Solution: min, max, factorial
- 6.32. Solution: Prime numbers
- 6.33. Solution: Many validator functions
- 6.34. Solution: Calculator using lookup table
7. Part 3
- 7.1. map with condtion
- 7.2. map with lambda
- 7.3. map with lambda with condition
- 7.4. List comprehension - complex
- 7.5. Change list before iteration over map object
- 7.6. Replace list before iteration over map object
- 8. Iterators - with and without Itertools
- 8.1. Advantages of iterators and generators
- 8.2. The Fibonacci research institute
- 8.3. Fibonacci plain
- 8.4. Fibonacci copy-paste
- 8.5. Iterators Glossary
- 8.6. What are iterators and iterables?
- 8.7. A file-handle is an iterator
- 8.8. range is iterable but it is not an iterator
- 8.9. Range with floating point steps
- 8.10. Iterator: a counter
- 8.11. Using iterator
- 8.12. Iterator without temporary variable
- 8.13. The type of the iterator
- 8.14. Using iterator with next
- 8.15. Mixing for and next
- 8.16. Iterable which is not an iterator
- 8.17. Iterator returning multiple values
- 8.18. Range-like iterator
- 8.19. Unbound or infinite iterator
- 8.20. Unbound iterator Fibonacci
- 8.21. Operations on Unbound iterator
- 8.22. itertools
- 8.23. itertools - count
- 8.24. itertools - cycle
- 8.25. Exercise: iterators - reimplement the range function
- 8.26. Exercise: iterators - cycle
- 8.27. Exercise: iterators - alter
- 8.28. Exercise: iterators - limit Fibonacci
- 8.29. Exercise: iterators - Fibonacci less memory
- 8.30. Exercise: read char
- 8.31. Exercise: read section
- 8.32. Exercise: collect packets
- 8.33. Exercise: compare files
- 8.34. Solution: iterators - limit Fibonacci
- 8.35. Solution: iterators - Fibonacci less memory
- 8.36. Solution: read section
- 8.37. Solution: compare files
- 8.38. Solution: collect packets
- 9. Generators and Generator Expressions
- 9.1. Generators Glossary
- 9.2. Iterators vs Generators
- 9.3. List comprehension and Generator Expression
- 9.4. List comprehension vs Generator Expression - less memory
- 9.5. List comprehension vs Generator Expression - lazy evaluation
- 9.6. Generator: function with yield - call next
- 9.7. Generators - call next
- 9.8. Generator with yield
- 9.9. Generators - fixed counter
- 9.10. Generators - counter
- 9.11. Generators - counter with parameter
- 9.12. Generators - my_range
- 9.13. Fibonacci - generator
- 9.14. Infinite series
- 9.15. Integers
- 9.16. Integers + 3
- 9.17. Integers + Integers
- 9.18. Filtered Fibonacci
- 9.19. The series.py
- 9.20. generator - unbound count (with yield)
- 9.21. iterator - cycle
- 9.22. Exercise: Alternator
- 9.23. Exercise: Prime number generator
- 9.24. Exercise: generator
- 9.25. Exercise: Binary file reader
- 9.26. Exercise: File reader with records
- 9.27. yield outside of functions
- 9.28. Operations on infinite lists
- 9.29. Infinite random number generator
- 9.30. Infinite random set generator
- 9.31. Simple function (before generators)
- 9.32. Filtered Fibonacci with ifilter