#include<stdio.h>
#include<string.h>
//八进制转十进制
int main()
{
char s[6],*p = s;
int n;
gets(p);
n = *p-‘0’; //把字符型数字转化成数值型数字的方法
while(*++p)
// while(*++p!=’\0′) //在数组中字符串的结束是以’\0’(它的ASCII是0)结尾的,这里是来判断是否到尾.
n = n * 8 + *p -‘0’;
printf(“%d\n”,n);
return 0;
}