ens-ulm-1-2015

google hashcode 2015 source for team ens-ulm-1
git clone https://a3nm.net/git/ens-ulm-1-2015/
Log | Files | Refs

commit 589273c5e72965dfeba49402865e6b490c7e37be
parent e9232dce6a562737ad59b6b916959b94a85571b6
Author: Antoine Amarilli <a3nm@a3nm.net>
Date:   Sat, 28 Mar 2015 14:00:31 +0100

fix

Diffstat:
contest/a3nm/main.cpp | 31++++++++++++++++---------------
1 file changed, 16 insertions(+), 15 deletions(-)

diff --git a/contest/a3nm/main.cpp b/contest/a3nm/main.cpp @@ -144,7 +144,7 @@ int planify(int b) { dir[t][a][r][c] = bestda; } } - simulate(b, &decide_dyn); + totscore += simulate(b, &decide_dyn); return totscore; } @@ -200,22 +200,23 @@ int main(int argc, char **argv) { for (int b = 0; b < B; b++) totscore += planify(b); + printf("score %d\n", totscore); print_sol(totscore); - // srand(42); - // while(true) { - // int br = (rand() % B); - // for (int t = 0; t <= T; t++) - // for (int l = 0; l < L; l++) - // covered[t][l] = false; - // // now simulate - // totscore = 0; - // for (int b = 0; b < B; b++) { - // if (br == b) - // continue; - // } - // - // } + //srand(42); + //while(true) { + // int br = (rand() % B); + // for (int t = 0; t <= T; t++) + // for (int l = 0; l < L; l++) + // covered[t][l] = false; + // // now simulate + // totscore = 0; + // for (int b = 0; b < B; b++) { + // if (br == b) + // continue; + // totscore += simulate(b, &decide_sol); + // } + //} return 0; }