#include <stdio.h>
#include <stdlib.h>
#include <time.h>
int main (void) {
int a [8];
int b [8];
int i;
int j;
int x;
int y;
time_t t;
srand((unsigned) time(&t));
for (i = 0; i < 8; i++) {
x = rand () % 8;
y = rand () % 8;
j = 0;
while (j < i) {
for (j = 0; j < i; j++) {
if (a[j] == x) {
x = rand () % 8;
break;
}
}
}
j = 0;
while (j < i) {
for (j = 0; j < i; j++) {
if (b[j] == y) {
y = rand () % 8;
break;
}
}
}
a [i] = x;
b [i] = y;
}
for (i = 0; i < 8; i++) {
printf ("%i | %i %i | %i\n", i, a[i], b[i], rand ()%2);
}
}