https://github.com/hyperxpro/hexdecimal
Convert Hex To Decimal and Decimal to Hex In Java
https://github.com/hyperxpro/hexdecimal
Last synced: 3 months ago
JSON representation
Convert Hex To Decimal and Decimal to Hex In Java
- Host: GitHub
- URL: https://github.com/hyperxpro/hexdecimal
- Owner: hyperxpro
- License: gpl-3.0
- Created: 2019-05-18T07:02:50.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2020-04-30T14:36:01.000Z (almost 6 years ago)
- Last Synced: 2025-01-19T09:29:53.984Z (about 1 year ago)
- Language: Java
- Homepage:
- Size: 49.8 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# HexDecimal
Convert Hex To Decimal and Decimal To Hex In Java
```Java
public class Main {
public static void main(String[] args) {
String Hex = "29374DB6F3488091C93C4816C11F4ACC";
HexToDecimal hexToDecimal = new HexToDecimal();
BigInteger decimal = hexToDecimal.getDecimalFromHex(Hex);
DecimalToHex decimalToHex = new DecimalToHex();
String DecimalToHex = decimalToHex.DecimalToHex(decimal);
System.out.println("Hex To Decimal: " + decimal);
System.out.println("Decimal To Hex: " + DecimalToHex);
/**
* Outputs:
*
* Hex To Decimal: 54785500394758532281144699898914884300
* Decimal To Hex: 29374DB6F3488091C93C4816C11F4ACC
*/
}
}
```