很简单的
public class Test{
private static void function7() {
Scanner sc=new Scanner(System.in);
int i=sc.nextInt();
System.out.println("二进制:"+Integer.toBinaryString(i));
System.out.println("八进制:"+Integer.toOctalString(i));
System.out.println("十六进制:"+Integer.toHexString(i));
}
}