in reply to Best way to make sure a number is an even multiple of another?
M goes into N int( N/M ) times, with a remainder of M%N.
So, M * (1 + int( N/M )) will be the smallest multiple of M greater then N.
--
TTTATCGGTCGTTATATAGATGTTTGCA
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Best way to make sure a number is an even multiple of another?
by Roy Johnson (Monsignor) on Oct 21, 2004 at 17:00 UTC |