c语言程序运行不了?来人啊!
看c primer 有个程序#include<stdio.h>
int main(void)
{
unsigned width,precision;
int number=256;
double weight=242.5;
printf("what field width?\n");
scanf("%d,&width");
printf("the number is:%*d: \n",width,number);
printf("now enter a width and a precision: \n");
scanf("%d %d",&width,&precision);
printf("weight=&*.*f\n",width,precision,weight);
return 0;
}
我在vs2010上运行的时候出现了第一排“what field width?”但是我随便输入一个数字,然后vs2010就崩溃了,哪位好心人能帮下