标签:lib can sys 数据 time_t void == and scanf
#include<stdio.h>
#include<stdlib.h>
#include<time.h>
void main()
{
time_t ts;
srand((unsigned int)time(&ts));
int a[10];
for (int i = 0; i < 10; i++)
{
a[10] = rand() % 100;
printf("\n%d,%x", a[10], &a[10]);
}
int num;
scanf("%d",&num);
int flag=0;
for (int i = 0; i < 10; i++)
{
if (num == a[i])
{
flag = 1;
break;
}
}
if (flag == 1)
{
printf("找到");
}
else
{
printf("找不到");
}
system("pause");
}
标签:lib can sys 数据 time_t void == and scanf
原文地址:https://www.cnblogs.com/minTTremor/p/9170442.html