Programming C, C++, Java, PHP, Ruby, Turing, VB
Computer Science Canada 
Programming C, C++, Java, PHP, Ruby, Turing, VB  

Username:   Password: 
 RegisterRegister   
 how to find next highest multiple of 10
Index -> Programming, Java -> Java Help
View previous topic Printable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
uberwalla




PostPosted: 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)?
Sponsor
Sponsor
Sponsor
sponsor
ericfourfour




PostPosted: 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.
uberwalla




PostPosted: Thu Feb 21, 2008 7:53 pm   Post subject: Re: how to find next highest multiple of 10

Problem solved. thanks
Display posts from previous:   
   Index -> Programming, Java -> Java Help
View previous topic Tell A FriendPrintable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 1 of 1  [ 3 Posts ]
Jump to:   


Style:  
Search: