编辑代码

#include <stdio.h>
#include<stdib.h>
#include<time.h>
int main () {
    int input1, times=0;
    stand(time(0));
    int a =rand()%100+1;
    printf("please guess");
    scanf("%d",&input1);
    do{
        times++
        if(times == 6){
            printf("Game over");
            break
        }
        else if (input1 < a){
            printf("your answer is smaller than the number");
            scanf("%d",&input1);
        }
        else if (input1 > a){
            printf("your answer is larger than the number\nPlease try again");
            scanf("%d",&input1);
        }
    }while input1 != a;
    if (times < 6){
        printf("congratulations, you are right!");
    }
    else (time >= 6){
        printf("GAME OVER,you try higher than 6 times");
    }
    return 0;
}