diff -r ea793ae43d3e -r 302ed98cb64c src/main/java/ru/alphatech/icfpc/game/AbstractPolicy.java --- a/src/main/java/ru/alphatech/icfpc/game/AbstractPolicy.java Mon Jun 20 01:48:37 2011 +0400 +++ b/src/main/java/ru/alphatech/icfpc/game/AbstractPolicy.java Mon Jun 20 01:59:45 2011 +0400 @@ -38,8 +38,12 @@ { ArrayList retArray = new ArrayList(); - retArray.addAll(smartAlg(0, number, targetSlot)); - + if(number == 0){ + retArray.add(new Batch(OperationType.CARD_TO_SLOT, new Put(), targetSlot)); + retArray.add(new Batch(OperationType.SLOT_TO_CARD, new Zero(), targetSlot)); + }else{ + retArray.addAll(smartAlg(0, number, targetSlot)); + } return retArray; } @@ -64,6 +68,9 @@ retArray.add(new Batch(OperationType.CARD_TO_SLOT, new Put(), targetSlot)); retArray.add(new Batch(OperationType.SLOT_TO_CARD, new Zero(), targetSlot)); retArray.add(new Batch(OperationType.CARD_TO_SLOT, new Succ(), targetSlot)); + + if(end == 0) + return retArray; } List list1 = buildNumberOperations(0, end, targetSlot);