From a87a40cbb838bd72d68953f3c9fd03797310c54f Mon Sep 17 00:00:00 2001 From: 0509leej-svg <0509leej@gmail.com> Date: Wed, 18 Feb 2026 16:30:56 -0500 Subject: [PATCH 1/7] John Lee - lab 1 python introduction --- labs/lab_1/lab_1a.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/labs/lab_1/lab_1a.py b/labs/lab_1/lab_1a.py index 9d15ec83..fc8d26ea 100644 --- a/labs/lab_1/lab_1a.py +++ b/labs/lab_1/lab_1a.py @@ -8,7 +8,7 @@ def main(): print("Hello World!") - name = "" # TODO: Insert your name between the double quotes + name = "John Lee" # TODO: Insert your name between the double quotes print(f"{name}, Welcome to the CSS course!") From c31373e5ca5ab0d286b5842aeb1b0b738ebba4e3 Mon Sep 17 00:00:00 2001 From: 0509leej-svg <0509leej@gmail.com> Date: Wed, 18 Feb 2026 18:51:46 -0500 Subject: [PATCH 2/7] Update lab_1a.py, robot speed change --- labs/lab_1/lab_1a.py | 1 + 1 file changed, 1 insertion(+) diff --git a/labs/lab_1/lab_1a.py b/labs/lab_1/lab_1a.py index fc8d26ea..7bc70572 100644 --- a/labs/lab_1/lab_1a.py +++ b/labs/lab_1/lab_1a.py @@ -1,3 +1,4 @@ +robot_speed = 5 # m/s """ lab_1a.py From 148d7e08a3179d0ac137f62a8e24b6f0e30e0bef Mon Sep 17 00:00:00 2001 From: 0509leej-svg <0509leej@gmail.com> Date: Wed, 18 Feb 2026 19:53:13 -0500 Subject: [PATCH 3/7] Changed speed from 5 to 3 --- labs/lab_1/lab_1a.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/labs/lab_1/lab_1a.py b/labs/lab_1/lab_1a.py index 7bc70572..449cfeaf 100644 --- a/labs/lab_1/lab_1a.py +++ b/labs/lab_1/lab_1a.py @@ -1,9 +1,10 @@ -robot_speed = 5 # m/s """ lab_1a.py The first lab in the BWSI CSS course. To complete this lab, fill out the variable on line 10 with your name. Then, save the code, add it to the staging area, and commit it to the Git tree. + +This is to simulate a change on a robot: robot_speed = 3 # m/s """ def main(): From 16fd2f285f088c79e92baf9832282b76d1f55fad Mon Sep 17 00:00:00 2001 From: 0509leej-svg <0509leej@gmail.com> Date: Wed, 18 Feb 2026 21:20:19 -0500 Subject: [PATCH 4/7] changed speed from 5 to 8 --- labs/lab_1/lab_1a.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/labs/lab_1/lab_1a.py b/labs/lab_1/lab_1a.py index 449cfeaf..d76feab4 100644 --- a/labs/lab_1/lab_1a.py +++ b/labs/lab_1/lab_1a.py @@ -4,7 +4,7 @@ The first lab in the BWSI CSS course. To complete this lab, fill out the variable on line 10 with your name. Then, save the code, add it to the staging area, and commit it to the Git tree. -This is to simulate a change on a robot: robot_speed = 3 # m/s +This is to simulate a change on a robot: robot_speed = 8 # m/s """ def main(): From 04d17ad911cf26b73d65988ca26ed22e3a87bf28 Mon Sep 17 00:00:00 2001 From: 0509leej-svg <0509leej@gmail.com> Date: Wed, 18 Feb 2026 21:57:45 -0500 Subject: [PATCH 5/7] changed 5 to 3 --- labs/lab_1/lab_1a.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/labs/lab_1/lab_1a.py b/labs/lab_1/lab_1a.py index d76feab4..449cfeaf 100644 --- a/labs/lab_1/lab_1a.py +++ b/labs/lab_1/lab_1a.py @@ -4,7 +4,7 @@ The first lab in the BWSI CSS course. To complete this lab, fill out the variable on line 10 with your name. Then, save the code, add it to the staging area, and commit it to the Git tree. -This is to simulate a change on a robot: robot_speed = 8 # m/s +This is to simulate a change on a robot: robot_speed = 3 # m/s """ def main(): From 33fb4dd11a9dff4e7ae36a294607eee5b1a31340 Mon Sep 17 00:00:00 2001 From: 0509leej-svg <0509leej@gmail.com> Date: Wed, 18 Feb 2026 23:07:56 -0500 Subject: [PATCH 6/7] Update lab_1b.py --- labs/lab_1/lab_1b.py | 24 +++++++++++++----------- 1 file changed, 13 insertions(+), 11 deletions(-) diff --git a/labs/lab_1/lab_1b.py b/labs/lab_1/lab_1b.py index e58dd957..4c33f961 100644 --- a/labs/lab_1/lab_1b.py +++ b/labs/lab_1/lab_1b.py @@ -40,16 +40,18 @@ def simple_calculator(operation: str, num1: float, num2: float) -> float: def main(): print(f"===== Simple Calculator =====") - - # Ask the user for sample input - num1 = float(input("Enter the first number: ")) - num2 = float(input("Enter the second number: ")) - operation = input("Enter the operation (add, subtract, multiply, divide): ").strip().lower() - - # Perform the calculation and display the result - result = simple_calculator(operation, num1, num2) - print(f"The result of {operation}ing {num1} and {num2} is: {result}") - - + + try: + # Ask the user for sample input + num1 = float(input("Enter the first number: ")) + num2 = float(input("Enter the second number: ")) + operation = input("Enter the operation (add, subtract, multiply, divide): ").strip().lower() + + # Perform the calculation and display the result + result = simple_calculator(operation, num1, num2) + print(f"The result of {operation}ing {num1} and {num2} is: {result}") + except ValueError: + print("Invalid input! Please enter a numerical value or a valid math operator.") + if __name__ == "__main__": main() From bf32347cace9f118038d890129aeb858dca65a79 Mon Sep 17 00:00:00 2001 From: 0509leej-svg <0509leej@gmail.com> Date: Thu, 19 Feb 2026 15:19:51 -0500 Subject: [PATCH 7/7] Unit Test Imports/Stuff