diff --git a/Notes/03_Program_organization/01_Script.md b/Notes/03_Program_organization/01_Script.md index 07bc91dd9..11fdb1809 100644 --- a/Notes/03_Program_organization/01_Script.md +++ b/Notes/03_Program_organization/01_Script.md @@ -102,7 +102,7 @@ def bar(x): statements # OR -def bar(x) +def bar(x): statements def foo(x): diff --git a/Notes/05_Object_model/01_Dicts_revisited.md b/Notes/05_Object_model/01_Dicts_revisited.md index 777d2843c..52760303c 100644 --- a/Notes/05_Object_model/01_Dicts_revisited.md +++ b/Notes/05_Object_model/01_Dicts_revisited.md @@ -248,7 +248,7 @@ You can view it. >>> ``` -This chain is called the **Method Resolution Order**. The find an +This chain is called the **Method Resolution Order**. To find an attribute, Python walks the MRO in order. The first match wins. ### MRO in Multiple Inheritance diff --git a/Notes/07_Advanced_Topics/00_Overview.md b/Notes/07_Advanced_Topics/00_Overview.md index 74005f17e..dacbcfa2a 100644 --- a/Notes/07_Advanced_Topics/00_Overview.md +++ b/Notes/07_Advanced_Topics/00_Overview.md @@ -1,4 +1,4 @@ -[Contents](../Contents.md) \| [Prev (6 Generators)](../06_Generators/00_Overview.md) \| [Next (8 Testing and Debugging](../08_Testing_debugging/00_Overview.md) +[Contents](../Contents.md) \| [Prev (6 Generators)](../06_Generators/00_Overview.md) \| [Next (8 Testing and Debugging)](../08_Testing_debugging/00_Overview.md) # 7. Advanced Topics diff --git a/Notes/07_Advanced_Topics/01_Variable_arguments.md b/Notes/07_Advanced_Topics/01_Variable_arguments.md index cc1f9efb0..6fe66ba0a 100644 --- a/Notes/07_Advanced_Topics/01_Variable_arguments.md +++ b/Notes/07_Advanced_Topics/01_Variable_arguments.md @@ -92,7 +92,7 @@ numbers = (2,3,4) f(1, *numbers) # Same as f(1,2,3,4) ``` -Dictionaries can also be expaded into keyword arguments. +Dictionaries can also be expanded into keyword arguments. ```python options = { diff --git a/Notes/08_Testing_debugging/00_Overview.md b/Notes/08_Testing_debugging/00_Overview.md index 37841d93c..d1c1bbc6a 100644 --- a/Notes/08_Testing_debugging/00_Overview.md +++ b/Notes/08_Testing_debugging/00_Overview.md @@ -1,6 +1,6 @@ [Contents](../Contents.md) \| [Prev (7 Advanced Topics)](../07_Advanced_Topics/00_Overview.md) \| [Next (9 Packages)](../09_Packages/00_Overview.md) -# 8. Overview +# 8. Testing and debugging This section introduces a few basic topics related to testing, logging, and debugging. diff --git a/Notes/09_Packages/01_Packages.md b/Notes/09_Packages/01_Packages.md index 24fcb35fe..96133bed8 100644 --- a/Notes/09_Packages/01_Packages.md +++ b/Notes/09_Packages/01_Packages.md @@ -243,7 +243,7 @@ package. One level up. ```python #!/usr/bin/env python3 -# porty-add/script.py +# porty-app/script.py import sys import porty diff --git a/Notes/Contents.md b/Notes/Contents.md index ef7299266..57199d7c0 100644 --- a/Notes/Contents.md +++ b/Notes/Contents.md @@ -16,7 +16,7 @@ Please see the [Instructor Notes](InstructorNotes.md) if you plan on teaching the course. -[Home](..) +[Home](../README.md) diff --git a/README.md b/README.md index e9538de6e..21efa4540 100644 --- a/README.md +++ b/README.md @@ -9,7 +9,8 @@ in-person groups since 2007. Traders, systems admins, astronomers, tinkerers, and even a few hundred rocket scientists who used Python to help land a rover on Mars--they've all taken this course. Now, I'm pleased to make it available under a Creative Commons license. Enjoy! -[GitHub Repo](https://github.com/dabeaz-course/practical-python). + +[GitHub Pages](https://dabeaz-course.github.io/practical-python) | [GitHub Repo](https://github.com/dabeaz-course/practical-python). --David Beazley ([https://dabeaz.com](https://dabeaz.com)), [@dabeaz](https://twitter.com/dabeaz) diff --git a/Solutions/1_10/mortgage.py b/Solutions/1_10/mortgage.py index 9d85119ad..dabd94fc3 100644 --- a/Solutions/1_10/mortgage.py +++ b/Solutions/1_10/mortgage.py @@ -15,7 +15,7 @@ principal = principal * (1+rate/12) - payment total_paid = total_paid + payment - if month >= extra_payment_start_month and month < extra_payment_end_month: + if month > extra_payment_start_month and month <= extra_payment_end_month: principal = principal - extra_payment total_paid = total_paid + extra_payment