Computer Science Canada how to find next highest multiple of 10 |
Author: | uberwalla [ Thu Feb 21, 2008 7:40 pm ] |
Post subject: | how to find next highest multiple of 10 |
Hey another quick question. This say i have the number 36. How would i get java to find out what the next power of ten is (ie 40)? |
Author: | ericfourfour [ Thu Feb 21, 2008 7:48 pm ] |
Post subject: | Re: how to find next highest multiple of 10 |
uberwalla @ Thu Feb 21, 2008 7:40 pm wrote: Hey another quick question.
This say i have the number 36. How would i get java to find out what the next power of ten is (ie 40)? I think you might have meant multiple here. The the modulu operator %. It works like the division operator except it returns the remainder. |
Author: | uberwalla [ Thu Feb 21, 2008 7:53 pm ] |
Post subject: | Re: how to find next highest multiple of 10 |
Problem solved. thanks |