You are given the partial code for a function, with only the body completed. You must
#FUNCTION HEADER (2 points)
#DOCSTRING (3 points)
#FUNCTION BODY - Do not change the code. You may copy-paste it into the answer-box but it is your choice. No marks for doing so)
return x*x
def square(x):
"""
Returns the square of number you input.
Parameters:
x (numeric): The number whose square is to be calculated.
Returns:
numeric: The square of the given number.
"""
return x*x
The given function returns square of the value, hence it
was named square.
Please upvote the answer if it helps you.
Get Answers For Free
Most questions answered within 1 hours.