import java.io.*; public class Test{ /** * 二进制与整型之间的转换 * @param args * @throws IOException */ public static void main(String args[])throws IOException{ //整型转二进制 int a = -1; int b = 1; System.out.println(Integer.toBinaryString(a)); System.out.println(…