Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public static boolean isMSBSet(int value) {
- boolean ret = false;
- String v = String.format("%x", value);
- switch (v.charAt(0)) {
- case 'F':
- case 'f':
- case 'E':
- case 'e':
- case 'C':
- case 'c':
- case 'B':
- case 'b':
- case 'A':
- case 'a':
- case '9':
- case '8':
- ret = true;
- }
- ret = (v.length() == 8) && ret;
- return ret;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement