1. Home
  2. Data Science
  3. Python
  4. Which of the following is an invalid integer in Python?

Added 4 May 2024

Which of the following is an invalid integer in Python?

  1. 123
  2. -456
  3. 0
  4. 12.34 Correct answer

Correct answer

D. 12.34

16 views

MCQSEXAM

Explanation

 Integers are whole numbers without any decimal points. 12.34 is a float, not an integer.

Doubts & discussion

Not sure why the answer is D? Ask here and get an explanation.

Ask a doubt about this MCQ

Shown after review. No links please.

More Python MCQs

Practise all Python MCQs

Similar MCQs