Q15
What is the purpose of the round() function in Python?
A.
To round up a number
B.
To round down a number
C.
To round a number to the nearest integer
D.
To round a number to a specified number of decimal places
AnswerAnswer: Option D
Solution
Answer: Option D
Solution:
The round() function rounds a number to a specified number of decimal places.