#include <cstdlib>#include <ctime> srand(time(NULL)); int x[64]={0};int y[32]; for(int i=0; i<32; ++i) y[i]=i+1; int aux; for(int j=0; j<2; ++j) for(int i=0; i<32; ++i) { aux=(rand()%64); if(x[aux]==0) { x[aux]=y[i]; } else --i; }