用java代码 8089174498B4变成8089174498B4
String macAddress = "8089174498B4";
String formattedMacAddress = macAddress.replaceAll("(?<=\\G..)(?!$)", ":");
System.out.println(formattedMacAddress);
输出结果为:80:89:17:44:98:B4
原文地址: https://www.cveoy.top/t/topic/fi1z 著作权归作者所有。请勿转载和采集!