Question PSC-OPS-0023
EasyWhat will be printed by the following pseudocode?
Print 17 mod 4
- A.
4
- B.
3
- C.
Show answer and explanation
Answer: D
mod gives the remainder: 17 = 4 × 4 + 1, so 17 mod 4 = 1.
Popular companies
Prepare company by company
Hiring pattern, syllabus, past questions and mocks for each company.
All companiesPractice by subject
Operators and Expressions question
What will be printed by the following pseudocode?
Print 17 mod 4
4
3
Answer: D
mod gives the remainder: 17 = 4 × 4 + 1, so 17 mod 4 = 1.
4.25
1