String s = "abcd";byte[] b = s.getBytes();int[] in = new int[b.length];for (int i = 0; i < in.length; i++) {in[i] = b[i]&0xff;}for (int j = 0; j < in.length; j++) {System.out.println(Integer.toString(in[j], 0x10));}