From 6e517929a242d7b969a952b3fd611d18f67c7b81 Mon Sep 17 00:00:00 2001 From: Rebecca Dang Date: Wed, 8 Jul 2020 11:23:13 -0700 Subject: [PATCH 1/2] Clarify instructions in Hours exercise --- 1_beginner/chapter4/practice/hours.py | 2 +- 1_beginner/chapter4/solutions/hours.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/1_beginner/chapter4/practice/hours.py b/1_beginner/chapter4/practice/hours.py index fa9b8e15..53d87890 100644 --- a/1_beginner/chapter4/practice/hours.py +++ b/1_beginner/chapter4/practice/hours.py @@ -1,7 +1,7 @@ # Hours # Write a program that asks the user # how many hours they spend on the internet -# per day, and return if they’re addicted +# per day, and print if they’re addicted # or not based on the hours. (5 or more hours # is addicted, less is not). diff --git a/1_beginner/chapter4/solutions/hours.py b/1_beginner/chapter4/solutions/hours.py index 8e5a97d8..87b964e1 100644 --- a/1_beginner/chapter4/solutions/hours.py +++ b/1_beginner/chapter4/solutions/hours.py @@ -1,7 +1,7 @@ # Hours # Write a program that asks the user # how many hours they spend on the internet -# per day, and return if they’re addicted +# per day, and print if they’re addicted # or not based on the hours. (5 or more hours # is addicted, less is not). From 724c8bfb019277814b204ab0d90381b1c259248a Mon Sep 17 00:00:00 2001 From: Rebecca Dang Date: Wed, 8 Jul 2020 11:23:28 -0700 Subject: [PATCH 2/2] Fix instructions in TV exercise to match what's on Thinkific --- 1_beginner/chapter5/practice/TV.py | 10 +++++----- 1_beginner/chapter5/solutions/TV.py | 22 +++++++++++----------- 2 files changed, 16 insertions(+), 16 deletions(-) diff --git a/1_beginner/chapter5/practice/TV.py b/1_beginner/chapter5/practice/TV.py index 9a2e1622..842bc783 100644 --- a/1_beginner/chapter5/practice/TV.py +++ b/1_beginner/chapter5/practice/TV.py @@ -1,9 +1,9 @@ # TV -# Pretend you just got a 37 on your test, -# and you mom says you can’t watch TV until you get above an 84. -# (HINT: comparison operators). You increase -# your test score 6 points per day (iterations). +# Pretend you just got a 50 on your test, +# and you mom says you can’t watch TV until you get +# a score of at least 80. (HINT: comparison operators). +# You increase your test score by 10 points per day. # Write a program that tells you after -# how many days you'll be able to watch TV +# how many days you'll be able to watch TV. Use a loop. # write code here diff --git a/1_beginner/chapter5/solutions/TV.py b/1_beginner/chapter5/solutions/TV.py index 510df61d..76f87a2e 100644 --- a/1_beginner/chapter5/solutions/TV.py +++ b/1_beginner/chapter5/solutions/TV.py @@ -1,14 +1,14 @@ # TV -# Pretend you just got a 37 on your test, -# and you mom says you can’t watch TV until you get above an 84. -# (HINT: comparison operators). You increase -# your test score 6 points per day (iterations). +# Pretend you just got a 50 on your test, +# and you mom says you can’t watch TV until you get +# a score of at least 80. (HINT: comparison operators). +# You increase your test score by 10 points per day. # Write a program that tells you after -# how many days you'll be able to watch TV +# how many days you'll be able to watch TV. Use a loop. -x = 37 -d = 0 -while x < 84: - x += 6 - d += 1 -print(d) +x = 50 +days = 0 +while x < 80: + x += 10 + days += 1 +print("You can watch TV after", days, "days")