Ask Question
8 January, 10:33

count multiples (num1, num2, AND) Description: Returns the number of multiples of N that exist between num1 and num2 inclusive. Parameters: num1 (int), num2 (int), N (int). num1 and num2 can be in any order. N cannot be 0. Return value: int Examples: count multiples (2, 13, 3) → 4 count_multiples (17, - 5, 4) → 6 count_multiples (-10, - 5, - 3) → 2

+1
Answers (1)
  1. 8 January, 13:18
    0
    def count_mutiples (num1, num2, N) : #make function for call

    count=0

    if (num1>num2) : #that will check which number is low and high

    low=num2

    high=num1

    else:

    high=num2

    low=num1

    for i in range (low, high+1):

    if (i%N==0):

    count=count+1

    return (count)
Know the Answer?
Not Sure About the Answer?
Find an answer to your question ✅ “count multiples (num1, num2, AND) Description: Returns the number of multiples of N that exist between num1 and num2 inclusive. Parameters: ...” in 📘 Computers and Technology if you're in doubt about the correctness of the answers or there's no answer, then try to use the smart search and find answers to the similar questions.
Search for Other Answers