What is the output of the following Python code snippet?
import math
print(math.sqrt(16))
print(math.sqrt(16))
Correct answer
B. 4.0
6 views
B. 4.0
6 views
math.sqrt always returns a float.
Asked in: Python Interview Advanced Python
https://docs.python.org/3/library/index.htmlNot sure why the answer is B? Ask here and get an explanation.