数组问题。求解
#include<stdio.h>#include<stdlib.h>
main()
{
int apple[10],i,h,d,total;
total=0;
printf("shen gao:\n");
scanf("%d",&h);
printf("apple de gao du:\n");
i=0;
while(i<10)
{
i=i+1;
scanf("%d",&apple[i]);
while(apple[i]<=h+30)
{total=total+1;
}}
printf("total=%d",total);
system("pause");
}
哪里出问题了。。。新手。。数组一直不懂。。求解