ProgrammingModerateTCS NQT · Wipro pattern

What is printed?

What is printed?
print(int('٠٠٢٩') + 1, '٢٩'.isdigit())
  1. A. 30 True
  2. B. 29 True
  3. C. 30 False
  4. D. 31 True

Correct answer: A. 30 True

Arabic-Indic digits are valid for int() and for isdigit(). The leading zeros do not change the value, so 29 plus 1 gives 30.

More Python Programming questions

Exams that ask this topic