aspose file tools*
The moose likes Programmer Certification (SCJP/OCPJP) and the fly likes Conversion Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Certification » Programmer Certification (SCJP/OCPJP)
Bookmark "Conversion" Watch "Conversion" New topic
Author

Conversion

Javix Protocol
Ranch Hand

Joined: Mar 21, 2000
Posts: 57
How to convert a decimal integer literal to octal and hexadecimal literal?
------------------
javix!


Write Once , Run Anytime ,Anywhere Forever And Smile Happily.
Jesper Ottosson
Ranch Hand

Joined: Mar 21, 2000
Posts: 51
the decimal number 20 is:
0x14 in hex
024 in oct
so just prefix with 0x when you want hexadecimal and 0 when you want octal
 
Don't get me started about those stupid light bulbs.
 
subject: Conversion