From d6b8a0691982dbaea1372e6e08b2558c8f776c1a Mon Sep 17 00:00:00 2001 From: jo2-holdsworth <jack2.holdsworth@live.uwe.ac.uk> Date: Wed, 5 Apr 2023 17:11:31 +0100 Subject: [PATCH] demo --- README.md | 13 ++++++++++++- morse.py | 4 ++-- 2 files changed, 14 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index fa2ebb9..a95d13e 100644 --- a/README.md +++ b/README.md @@ -14,6 +14,7 @@ - [Task 2: Python encode / decode.](#task-2-python-encode--decode) - [Task 3: Unit testing.](#task-3-unit-testing) - [Task 4: Expanding capability.](#task-4-expanding-capability) + - [Demos](#demos) - [Getting Started](#getting-started) - [Dependencies](#dependencies) - [Installing](#installing) @@ -68,7 +69,17 @@ ___ * ***inserter.py*** is designed to take an heap string and add values to that heap. It also will add new layers by adding the correct amount of Null characters. This is what the tree looks like in heap form now.. The function to insert is very simple and the next worksheet builds on a similar method so it will be very useful.  When we run our new characters to be inserted  we get . * ***morse.py*** To simple update the binary tree with new values we just add it to **initTree()** like this.  * ***unittesting*** after testing some of the new values we get no unexpected errors.  - +___ +## Demos +* ***Task 1:*** + <iframe width="560" height="315" src="https://www.youtube.com/embed/AjLuZGTohQ0" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" allowfullscreen></iframe> +* ***Task 2:*** + <iframe width="560" height="315" src="https://www.youtube.com/embed/DksW8h8woP4" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" allowfullscreen></iframe> +* ***Task 3:*** + <iframe width="560" height="315" src="https://www.youtube.com/embed/ofvF_PM0YXk" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" allowfullscreen></iframe> +* ***Task 4:*** + <iframe width="560" height="315" src="https://www.youtube.com/embed/8c6kVIacqw0" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" allowfullscreen></iframe> +___ ## Getting Started * To include it in another file: diff --git a/morse.py b/morse.py index b4b5259..bc20606 100644 --- a/morse.py +++ b/morse.py @@ -153,6 +153,6 @@ def decode(value): if __name__ == '__main__': print("=== Task 2 by Jack H ===") - print(f"Encode ('Task 2 by Jack H'): {encode('Task 2 by Jack H')}") - print(f"Decode ('- .- ... -.- ..--- -... -.-- .--- .- -.-. -.- ....): {decode('- .- ... -.- ..--- -... -.-- .--- .- -.-. -.- ....')}") + print(f"Encode ('Task 2 by Jack H &'): {encode('Task 2 by Jack H &')}") + print(f"Decode ('- .- ... -.- ..--- -... -.-- .--- .- -.-. -.- .... .-...'): {decode('- .- ... -.- ..--- -... -.-- .--- .- -.-. -.- .... .-...')}") print("========================") \ No newline at end of file -- GitLab