1.1 --- a/icfp-solver/src/main/java/ru/bosony/solvers/AbstractSolver.java Tue Jul 17 21:38:39 2012 +0400
1.2 +++ b/icfp-solver/src/main/java/ru/bosony/solvers/AbstractSolver.java Wed Jul 18 01:25:43 2012 +0400
1.3 @@ -1,7 +1,6 @@
1.4 package ru.bosony.solvers;
1.5
1.6 import java.text.DecimalFormat;
1.7 -import java.util.Date;
1.8 import java.util.HashSet;
1.9 import java.util.Set;
1.10
1.11 @@ -15,14 +14,14 @@
1.12 */
1.13 public abstract class AbstractSolver {
1.14
1.15 - protected Mine mine = null;
1.16 + protected Mine initialMine = null;
1.17 protected SolverListener listener = null;
1.18 protected Set<Game> games = new HashSet<Game>();
1.19 protected long attemptsCount = 0;
1.20 protected long startTime = System.currentTimeMillis();
1.21
1.22 public AbstractSolver(Mine mine, SolverListener listener) {
1.23 - this.mine = mine;
1.24 + this.initialMine = mine;
1.25 this.listener = listener;
1.26 }
1.27
1.28 @@ -34,8 +33,8 @@
1.29 listener.foundNextRoute(game.getStringRoute());
1.30 // TODO delete
1.31 System.out.println(new DecimalFormat("0.00").format((((System.currentTimeMillis() - startTime) / 1000d)))
1.32 - + " seconds, State = " + game.getState() + ", Score = " + game.getScore() + ", Route = "
1.33 - + game.getStringRoute());
1.34 + + " seconds, State = " + game.getState() + ", Score = " + game.getScore() + ", Route("
1.35 + + game.getRoute().size() + ") = " + game.getStringRoute());
1.36 }
1.37 games.add(game);
1.38 }