/**
* Charset: Unicode, Character encoding: UTF-8
*/
public class BinaryToChar {
public static void main(String[] args) {
String[] binary = {"100111101100000", "1000111111011000", "111011100011111", "110011000101111", "110011101100001", "111001011010111", "101010101001010"};
String str = "";
for (String value : binary) {
char ideograph = (char) Integer.parseInt(value, 2);
str += ideograph;
}
System.out.println("转换的字符串为:" + str);
}
}
通过二进制转换为字符
最新推荐文章于 2022-08-10 09:59:44 发布