Created
March 1, 2021 11:56
-
-
Save Alkimisti/ffe90127fccf99701ca81ffc63dae01f to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class Decimal2Hexadecimal { | |
public static void main(String[] args) { | |
String hex1 = Integer.toHexString(16); | |
System.out.println(hex1); | |
String hex2 = Integer.toHexString(128); | |
System.out.println(hex2); | |
String hex3 = Integer.toHexString(255); | |
System.out.println(hex3); | |
} | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment