A

Admin • 828.03K Points
Coach

Q. What does the `range(5)` function return?

  • (A) A list from 1 to 5
  • (B) A list from 0 to 5
  • (C) A range object from 0 to 4
  • (D) An error
  • Correct Answer - Option(C)
  • Views: 7
  • Filed under category Python
  • Hashtags:

Explanation by: Admin
`range(5)` creates a range from 0 up to, but not including, 5.

You must be Logged in to update hint/solution

Discusssion

Login to discuss.

Be the first to start discuss.