Find the Next Number Divisible by y
Write a function next_divisible that takes two integers, x and y, as arguments. The function should check if x is divisible by y. If it is, return x. If not, return the next higher natural number that is divisible by y. Hint: remember the modulo operator
%
? You could use it to check if a number is divisible by y.Premium
Python
Setting up Python environment...
Output