package acm;
import java.util.Scanner;
public class L3_2 {
/** * @param args */
public static void main(String[] args) {
// TODO Auto-generated method stub
Scanner scan=new Scanner(System.in);
int a[]=new int[1000];
int n=scan.nextInt();
int i=0;
int sum=0;
while(n>0){
a[i]=n%10;
n=n/10;
sum=(int) (sum+a[i]*Math.pow(8, i));
i++;
}
System.out.println(sum);
}
}
时间: 2024-09-29 23:30:40