← Quiz: Modules and Libraries: all 14 questions
Quiz: Modules and Libraries · Question 6 of 14
What does this print? (code)
What does this print?
import math
print(math.ceil(4.1), math.floor(4.9))
- A.5 4
- B.4 5
- C.4 4
- D.5 5
Answer & explanation
Correct answer: 5 4
ceil rounds up, floor rounds down.
Can you get the rest right without peeking?
Take the timed Quiz: Modules and Libraries quiz free. Pass it to earn XP and count towards your certificate.
Start the quiz →