Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update 021_two_step.py #39

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 7 additions & 5 deletions 021_two_step.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,10 @@ def add_one_and_divide_by_two_with_an_expression(num):
print("Function: divide_by_two_and_add_one")

def divide_by_two_and_add_one(num):
# Divide num by two and add one to the result
pass # <-- This does nothing, replace it with your code

divide=num/2
added=divided+1
return added

check_that_these_are_equal(
divide_by_two_and_add_one(6),
4.0
Expand All @@ -66,8 +67,9 @@ def multiply_by_forty_and_add_sixty(num):
print("Function: add_together_and_double")

def add_together_and_double(num_a, num_b):
# Add together num_a and num_b, then double the result
pass # <-- This does nothing, replace it with your code
added=num_a+num_b
doubled=added*2
return doubled

check_that_these_are_equal(
add_together_and_double(3, 4),
Expand Down