c语言入门,在学翁恺教授的慕课6.2.9
软件 devc++ 6.5
c=i;写在输入行后,会编译正常。
######我想知道c=i;写在scanf前一行时 为什么会报错。
#include<stdio.h>
int main() {
int i;
char c;
c = i;
scanf ("%d", &i);
printf("c=%d\n", c);
printf("c='%c'In", c);
return 0;
}
报错
[Warning] 'i' is used uninitialized in this function [-Wuninitialized]