From 1e740c7ff8cfb4781d61fb243b935d90bce1a62d Mon Sep 17 00:00:00 2001 From: baphim <269010393+baphim@users.noreply.github.com> Date: Wed, 30 Sep 2026 14:34:23 -0400 Subject: [PATCH] feat: created all deliverable files for Lab 3_4 --- lab-3_4/P-1.29.py | 4 ++++ lab-3_4/P-1.30.py | 4 ++++ lab-3_4/P-1.31.py | 7 +++++++ lab-3_4/P-1.32.py | 6 ++++++ 4 files changed, 21 insertions(+) create mode 100644 lab-3_4/P-1.29.py create mode 100644 lab-3_4/P-1.30.py create mode 100644 lab-3_4/P-1.31.py create mode 100644 lab-3_4/P-1.32.py diff --git a/lab-3_4/P-1.29.py b/lab-3_4/P-1.29.py new file mode 100644 index 0000000..eb94f53 --- /dev/null +++ b/lab-3_4/P-1.29.py @@ -0,0 +1,4 @@ +""" +Write a Python program that outputs all possible strings formed by using the chagacters 'c', 'a', 't', 'd', 'o', and 'g' +exactly once. +""" \ No newline at end of file diff --git a/lab-3_4/P-1.30.py b/lab-3_4/P-1.30.py new file mode 100644 index 0000000..cc2c434 --- /dev/null +++ b/lab-3_4/P-1.30.py @@ -0,0 +1,4 @@ +""" +Write a Python program that can take a positive integer greater than 2 as input and write out the number of times +one must repeatedly divide this number by 2 before getting a value less than 2. +""" \ No newline at end of file diff --git a/lab-3_4/P-1.31.py b/lab-3_4/P-1.31.py new file mode 100644 index 0000000..914700b --- /dev/null +++ b/lab-3_4/P-1.31.py @@ -0,0 +1,7 @@ +""" +Write a Python program that can "make change". Your program should take two numbers as input, one that is a monetary +amount charged and the other that is a monetary amount given. It should then return the number of each kind of bill and +coin to give back as change for the difference between the amount given and the amount charged. The values assigned +to the bills and coins can be based on the monetary system of any current or former government. Try to design your +program so that it returns as few bills and coins as possible. +""" \ No newline at end of file diff --git a/lab-3_4/P-1.32.py b/lab-3_4/P-1.32.py new file mode 100644 index 0000000..f9e3981 --- /dev/null +++ b/lab-3_4/P-1.32.py @@ -0,0 +1,6 @@ +""" +Write a Python program that can simulate a simple calculator, using the console as the exclusive input and output +device. That is, each input to the calculator, be it a number, like 12.34 or 1034, or an operator, like + or =, can be +done on a separate line. After each such input, you should output to the Python console what would be displayed on your +calculator. +""" \ No newline at end of file