#include#includeint main(){ int i=1,j=0; int a[10]={1,2,3,4,5,6,7,8,9,10}; srand(time(NULL)); while(i<=10) { j=rand()%10; if(a[j]!=0) { printf("第%d个数为:%d\n",i,a[j]); a[j]=0; i++; } } return 0;}