Skip to content

Commit

Permalink
First Refresh for Fall 21
Browse files Browse the repository at this point in the history
Closed #3 , Closed #4
  • Loading branch information
Peter Nardi committed May 28, 2021
1 parent ed4de87 commit 07d328e
Show file tree
Hide file tree
Showing 32 changed files with 477 additions and 429 deletions.
142 changes: 66 additions & 76 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,81 +2,71 @@

This is a collection of Jupyter Notebooks for teaching Python programming with an emphasis on the fundamentals of Cyber Operations. It's not meant to be a complete Python textbook, but rather an organized reference guide to allow you to see interactive examples on specific Python topics.

## Topics

1. Introduction
* Using Jupyter Notebooks
* Your first Python program


2. Basic operations
* Variables, assignment statements, expressions
* Reading console input
* Numeric data types
* Operator precedence
* Strings
* Type conversions


3. Built-in Functions and Objects
* Common functions
* Objects and methods
* Formatting output with `.format()`


4. Branch Logic
* Boolean data types
* `if` statements
* `if` - `else` statements
* `if` - `elif` - `else` statements
* Logical operators (`and`, `or`, `not`)
* Operator precedence


5. Iteration (Loops)
* `for` loop
* `while` loop
* Nested loops
* `break` and `continue`


6. User Defined Functions
* Introduction
* Defining functions
* Calling functions
* Arguments and parameters
* Variable scope


7. Collections: Lists, Dictionaries, Sets, Tuples
* Creating
* Accessing data
* Functions - returning multiple values
* Functions - pass by value; pass by reference


8. File I/O
* Modes: read (`'r'`), write (`'w'`), append(`'a'`)
* Writing and closing: `write()`, `close()`
* Ways to read: `read()`, `readline()`, `readlines()`


9. Hashing
* Hashing strings


10. Exception Handling
* Catching exceptions
* Raising exceptions


11. Recursion
* Introduction
* Examples


12. OOP
* User defined classes
*Python 3.8.x is currently shipping with Ubuntu 20.04.x.
*

## Topics

13. Misc Topics
1. Introduction
* Using Jupyter Notebooks
* Your first Python program
<br/><br/>
2. Basic operations
* Variables, assignment statements, expressions
* Reading console input
* Numeric data types
* Operator precedence
* Strings
* Type conversions
<br/><br/>
3. Built-in Functions and Objects
* Common functions
* Objects and methods
* Formatted String Literals (f-strings)
<br/><br/>
4. Branch Logic
* Boolean data types
* `if` statements
* `if` - `else` statements
* `if` - `elif` - `else` statements
* Logical operators (`and`, `or`, `not`)
* Operator precedence
<br/><br/>
5. Iteration (Loops)
* `for` loop
* `while` loop
* Nested loops
* `break` and `continue`
<br/><br/>
6. User Defined Functions
* Introduction
* Defining functions
* Calling functions
* Arguments and parameters
* Variable scope
<br/><br/>
7. Collections: Lists, Dictionaries, Sets, Tuples
* Creating
* Accessing data
* Functions - returning multiple values
* Functions - pass by value; pass by reference
<br/><br/>
8. File I/O
* Modes: read (`'r'`), write (`'w'`), append(`'a'`)
* Writing and closing: `write()`, `close()`
* Ways to read: `read()`, `readline()`, `readlines()`
<br/><br/>
9. Hashing
* Hashing strings
<br/><br/>
10. Exception Handling
* Catching exceptions
* Raising exceptions
<br/><br/>
11. Recursion
* Introduction
* Examples
<br/><br/>
12. OOP
* User defined classes
<br/><br/>
13. Misc Topics
144 changes: 66 additions & 78 deletions content/00_tableOfContents.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -10,82 +10,70 @@
"\n",
"## Topics\n",
"\n",
"1. Introduction\n",
" * Using Jupyter Notebooks\n",
" * Your first Python program\n",
" \n",
" \n",
"2. Basic operations\n",
" * Variables, assignment statements, expressions\n",
" * Reading console input\n",
" * Numeric data types\n",
" * Operator precedence\n",
" * Strings\n",
" * Type conversions\n",
" \n",
" \n",
"3. Built-in Functions and Objects\n",
" * Common functions\n",
" * Objects and methods\n",
" * Formatting output with `.format()`\n",
" \n",
" \n",
"4. Branch Logic\n",
" * Boolean data types\n",
" * `if` statements\n",
" * `if` - `else` statements\n",
" * `if` - `elif` - `else` statements\n",
" * Logical operators (`and`, `or`, `not`)\n",
" * Operator precedence\n",
" \n",
" \n",
"5. Iteration (Loops)\n",
" * `for` loop\n",
" * `while` loop\n",
" * Nested loops\n",
" * `break` and `continue`\n",
" \n",
"\n",
"6. User Defined Functions\n",
" * Introduction\n",
" * Defining functions\n",
" * Calling functions\n",
" * Arguments and parameters\n",
" * Variable scope\n",
" \n",
" \n",
"7. Collections: Lists, Dictionaries, Sets, Tuples\n",
" * Creating\n",
" * Accessing data\n",
" * Functions - returning multiple values\n",
" * Functions - pass by value; pass by reference\n",
"\n",
" \n",
"8. File I/O\n",
" * Modes: read (`'r'`), write (`'w'`), append(`'a'`)\n",
" * Writing and closing: `write()`, `close()`\n",
" * Ways to read: `read()`, `readline()`, `readlines()`\n",
" \n",
"\n",
"9. Hashing\n",
" * Hashing strings\n",
"\n",
"\n",
"10. Exception Handling\n",
" * Catching exceptions\n",
" * Raising exceptions\n",
" \n",
" \n",
"11. Recursion\n",
" * Introduction\n",
" * Examples\n",
"\n",
"\n",
"12. OOP\n",
" * User defined classes\n",
"\n",
"\n",
"13. Misc Topics\n"
"1. Introduction\n",
" * Using Jupyter Notebooks\n",
" * Your first Python program\n",
" <br/><br/>\n",
"2. Basic operations\n",
" * Variables, assignment statements, expressions\n",
" * Reading console input\n",
" * Numeric data types\n",
" * Operator precedence\n",
" * Strings\n",
" * Type conversions\n",
" <br/><br/>\n",
"3. Built-in Functions and Objects\n",
" * Common functions\n",
" * Objects and methods\n",
" * Formatted String Literals (f-strings)\n",
" <br/><br/>\n",
"4. Branch Logic\n",
" * Boolean data types\n",
" * `if` statements\n",
" * `if` - `else` statements\n",
" * `if` - `elif` - `else` statements\n",
" * Logical operators (`and`, `or`, `not`)\n",
" * Operator precedence\n",
" <br/><br/>\n",
"5. Iteration (Loops)\n",
" * `for` loop\n",
" * `while` loop\n",
" * Nested loops\n",
" * `break` and `continue`\n",
" <br/><br/>\n",
"6. User Defined Functions\n",
" * Introduction\n",
" * Defining functions\n",
" * Calling functions\n",
" * Arguments and parameters\n",
" * Variable scope\n",
" <br/><br/>\n",
"7. Collections: Lists, Dictionaries, Sets, Tuples\n",
" * Creating\n",
" * Accessing data\n",
" * Functions - returning multiple values\n",
" * Functions - pass by value; pass by reference\n",
" <br/><br/>\n",
"8. File I/O\n",
" * Modes: read (`'r'`), write (`'w'`), append(`'a'`)\n",
" * Writing and closing: `write()`, `close()`\n",
" * Ways to read: `read()`, `readline()`, `readlines()`\n",
" <br/><br/>\n",
"9. Hashing\n",
" * Hashing strings\n",
" <br/><br/>\n",
"10. Exception Handling\n",
" * Catching exceptions\n",
" * Raising exceptions\n",
" <br/><br/>\n",
"11. Recursion\n",
" * Introduction\n",
" * Examples\n",
" <br/><br/>\n",
"12. OOP\n",
" * User defined classes\n",
" <br/><br/>\n",
"13. Misc Topics"
]
},
{
Expand All @@ -96,7 +84,7 @@
"\n",
"*MIT License*\n",
"\n",
"*Copyright 2019-2020 Peter Nardi*\n",
"*Copyright 2019-2021 Peter Nardi*\n",
"\n",
"*Terms of use:*\n",
"\n",
Expand Down Expand Up @@ -124,7 +112,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.8.2"
"version": "3.8.5"
}
},
"nbformat": 4,
Expand Down
12 changes: 6 additions & 6 deletions content/01_intro00.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
"* A cell is selected if you see a blue bar to its left.\n",
"* To minimize a cell, click once on its blue bar. Click the blue bar again to expand.\n",
"* To edit a code cell, click on it.\n",
"* To run a code cell, make sure it's selected and press **Cntl-Enter**.\n",
"* To run a code cell, make sure it's selected, then hold the <kbd>control</kbd> key and press <kbd>enter</kbd> (<kbd>control</kbd>+<kbd>enter</kbd>).\n",
" * You can repeatedly run a cell as long as it's highlighted. Each re-run of a cell will start by clearing its output.\n",
"* To clear the output in a code cell: Right-click it; select **Clear Outputs**.\n",
"* To clear the output for all code cells in a notebook, right-click on the window and select **Clear All Outputs**"
Expand Down Expand Up @@ -49,8 +49,8 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"- To run the code below, click (once) on the code block, hold the `Control` key and press the `Enter` key (`Cntl-Enter`).\n",
"- To re-run the code, press `Cntl-Enter` again.\n",
"- To run the code below, click (once) on the code block, hold the <kbd>control</kbd> key and press the <kbd>enter</kbd> key (<kbd>control</kbd>+<kbd>enter</kbd>).\n",
"- To re-run the code, press <kbd>control</kbd>+<kbd>enter</kbd> again.\n",
"- To clear the output, right-click on the cell and select `Clear Outputs`"
]
},
Expand Down Expand Up @@ -119,7 +119,7 @@
"\n",
"Don't worry :-)\n",
"\n",
"If you double-click a text cell you put it in *edit mode*. Text cells are written in a language called [markdown](https://www.markdownguide.org/getting-started/) and double-clicking on one allows you to edit the underlying content. If you accidentally double-click on one, just \"run\" the cell like you would a code cell (holding the `Control` key and pressing the `Enter` key). This will put it back into *display mode*. Go ahead and try it. Double-click this cell to enter *edit mode*, then press `Control-Enter` to put it back into *display mode*.\n",
"If you double-click a text cell you put it in *edit mode*. Text cells are written in a language called [markdown](https://www.markdownguide.org/getting-started/) and double-clicking on one allows you to edit the underlying content. If you accidentally double-click on one, just \"run\" the cell like you would a code cell (using <kbd>control</kbd>+<kbd>enter</kbd>). This will put it back into *display mode*. Go ahead and try it. Double-click this cell to enter *edit mode*, then use <kbd>control</kbd>+<kbd>enter</kbd> to put it back into *display mode*.\n",
"\n",
"You shouldn't have a need to manipulate text cells in these notebooks, but if you put one in *edit mode* by mistake, now you know how to put it back into *display mode*."
]
Expand Down Expand Up @@ -162,7 +162,7 @@
"\n",
"*MIT License*\n",
"\n",
"*Copyright 2019-2020 Peter Nardi*\n",
"*Copyright 2019-2021 Peter Nardi*\n",
"\n",
"*Terms of use:*\n",
"\n",
Expand Down Expand Up @@ -190,7 +190,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.8.2"
"version": "3.8.5"
}
},
"nbformat": 4,
Expand Down
Loading

0 comments on commit 07d328e

Please sign in to comment.