You have a set of different lines of code that utilizes a specific Python module to calculate the circumference of a circle given the radius. Your job is to reorder these lines of code to form a complete, executable Python program that takes a radius of 5 as input and prints out the correct circumference. Make sure to load the needed module correctly for the calculation function to work.
Constructing a circle's circumference calculator
Report a typo
Reorder lines using drag or arrows. Adjust indentation with left buttons
return 2 * math.pi * radius
def calculate_circumference(radius):
import math
circumference = calculate_circumference(5)
print(str(circumference))
Create a free account to access the full topic
By continuing, you agree to the JetBrains Academy Terms of Service as well as Hyperskill Terms of Service and Privacy Policy.