Loop until supervisor exits
This commit is contained in:
parent
93131dc027
commit
5fe85da2ef
34
generator.c
34
generator.c
@ -303,24 +303,24 @@ int main(int argc, char *argv[])
|
|||||||
int permutation[graph.V];
|
int permutation[graph.V];
|
||||||
|
|
||||||
while (quit == 0) {
|
while (quit == 0) {
|
||||||
for (int i = 0; i < 10000000; i++) {
|
if (shared->quit == 1)
|
||||||
int solution[MAX_ITEMS];
|
break;
|
||||||
genSolution(permutation, graph.V, solution);
|
|
||||||
printf("[");
|
int solution[MAX_ITEMS];
|
||||||
if (solution[0] == -1) {
|
genSolution(permutation, graph.V, solution);
|
||||||
printf("]\n");
|
printf("[");
|
||||||
break;
|
if (solution[0] == -1) {
|
||||||
}
|
printf("]\n");
|
||||||
int j;
|
break;
|
||||||
for (j = 0; j < (MAX_ITEMS - 1); j++) {
|
|
||||||
if (solution[j+1] != -1)
|
|
||||||
printf("%d, ", solution[j]);
|
|
||||||
else
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
printf("%d]\n", solution[j]);
|
|
||||||
}
|
}
|
||||||
break;
|
int j;
|
||||||
|
for (j = 0; j < (MAX_ITEMS - 1); j++) {
|
||||||
|
if (solution[j+1] != -1)
|
||||||
|
printf("%d, ", solution[j]);
|
||||||
|
else
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
printf("%d]\n", solution[j]);
|
||||||
}
|
}
|
||||||
|
|
||||||
cleanup();
|
cleanup();
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user