Run the program in Block::Codes IDE.
To round off an integer i to the next largest even multiple of another integer j, the following formula can be used:
Next_multiple = i + j - i%j
For example, to round off 256 days to the next largest number of days evenly divisible by a week, values of i = 256 and j = 7 can be substituted into the preceding formula as follows:
Next_multiple = 256 + 7 - 256%7 = 256 + 7 - 4 = 259
Write a program to find the next largest even multiple for the following values of i and j:
i: 365, 12258, 996
j: 7, 23, 4