Write the pseudocode to print all multiples of 5 between 10 and 25 (including both 10 and 25).
Question
Write the pseudocode to print all multiples of 5 between 10 and 25 (including both 10 and 25).
✨ Free AI Tools for You
Powered by Chatterbot AI
Answer
Here’s the pseudocode to print all multiples of 5 between 10 and 25, inclusive:
PRINT "Multiples of 5 between 10 and 25:"
FOR number FROM 10 TO 25 STEP 1
IF (number MOD 5 == 0) THEN
PRINT number
END IF
NEXT number
This pseudocode uses a loop that iterates through each number from 10 to 25 and checks if it is a multiple of 5 by using the modulus operator. If the condition is true, the number is printed.
India's 1st AI Doubt Solver for CBSE, JEE, and NEET
Ask a Question for Freeand then it's just ₹212 a month