Skip to content

Instantly share code, notes, and snippets.

@jskeet
Created March 27, 2019 09:01
Show Gist options
  • Select an option

  • Save jskeet/fda32346c7600cfb1449b94907c03df5 to your computer and use it in GitHub Desktop.

Select an option

Save jskeet/fda32346c7600cfb1449b94907c03df5 to your computer and use it in GitHub Desktop.
public class Test {
public static void main(String[] args) {
String filename = "abc";
for (int i = 0; i < filename.length(); i++) {
System.out.printf("%04x%n", (int) filename.charAt(i));
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment