Ideas: to give a composition according to the digital input on each digital octal digit, and then subjected to a combination (combination, a combination of a decimal)
Code:
public class Demo1 {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int a = sc.nextInt();
int ge = a%8;
int shi = a/8%8;
int bai = a/8/8%8;
int qian = a/8/8/8%8;
int ba = ge+shi*10+bai*10*10+qian*10*10*10;
System.out.println(ba);
}
}
operation result: