这个猜数字游戏错哪里了?
#include<stdio.h>#include<stdlib.h>
#include<time.h>
int main(void)
{
srand((unsigned) time(0));
int number = rand ()%100 + 1;
int count = 0;
int a = 0;
printf("请猜数字");
scanf("%d",&a);
count++;
while(count = 1,count++)
{
if (a = number){
printf("Bingo!");
}
else if (0<=a<number){
printf("Too small,请继续猜数字\n");
}
else if (a>number){
printf("Too big,请继续猜数字\n");
}
else{
printf("Game Over");
}
}
while(1 < count <= 3, count++)
{
if (a = number){
printf("Lucky You!");
}
else if(0<= a < number){
printf("Too small,请继续猜数字\n");
}
else if(a >= number){
printf("Too big,请继续猜数字\n");
}
else{
printf("Game Over");
}
}
while(count>3,count++)
{
if (a = number){
printf("Good Guess!");
}
else if(0 <= a < number){
printf("Too small,请继续猜数字\n");
}
else if(a > number){
printf("Too big,请继续猜数字\n");
}
else{
printf("Game Over");
}
}
return 0;
}