MCQs > IT & Programming > Python > Which is the correct code for obtaining a random whole number from 1 to 1,000,000 in Python 2.x?

Python MCQs

Which is the correct code for obtaining a random whole number from 1 to 1,000,000 in Python 2.x?

Answer

Correct Answer: import random; x = random.randint(1,1000000)

Explanation:

Note: This Question is unanswered, help us to find answer for this one

Python Skill Assessment

Overall Skill Level-Poor

Your Skill Level: Poor

Retake Quizzes to improve it

search

Python Skill Assessment

Overall Skill Level-Poor

Your Skill Level: Poor

Retake Quizzes to improve it