Skip to content

Commit

Permalink
Fixup
Browse files Browse the repository at this point in the history
  • Loading branch information
neongreen committed May 4, 2024
1 parent 679cd18 commit cf7fa22
Show file tree
Hide file tree
Showing 5 changed files with 109 additions and 141 deletions.
30 changes: 11 additions & 19 deletions golden-games/b8add891-a281-4569-9875-b6cce63f9338/depth-1.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,24 +4,16 @@
... Nh6 0.00
3. a4 +0.02
... a5 0.00
4. Ra2 +0.20
... Ra7 0.00
5. b4 +0.02
4. b4 +0.02
... axb4 -1.01
6. Ba3 -0.81
... bxc3 -4.02
7. dxc3 -2.97
... Rxa4 -3.99
8. Qd2 -3.79
... Rxa3 -6.99
9. Rxa3 -1.79
... b5 -1.81
10. e4 -1.79
... Bb7 -1.99
11. Ke2 -1.79
... d5 -1.81
12. exd5 -0.78
... Qxd5 -2.01
13. f4 -1.99
... Qxd2 -11.19
5. d4 -0.99
... bxc3 -4.20
6. Bd2 -4.00
... cxd2 -7.21
7. Kxd2 -5.96
... Rxa4 -7.18
8. c4 -7.16
... Rxa1 -12.16
9. e4 -12.14
... Rxd1 -21.14
Challenge lost - no moves available
88 changes: 36 additions & 52 deletions golden-games/b8add891-a281-4569-9875-b6cce63f9338/depth-2.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,58 +4,42 @@
... Nh6 +0.02
3. a4 0.00
... a5 +0.20
4. Ra2 0.00
4. e4 -0.18
... Ra7 +0.02
5. e4 0.00
5. Qe2 0.00
... e5 +0.20
6. Qe2 0.00
... Qe7 +0.02
7. b3 -0.01
... b6 +0.20
8. d3 -0.19
... Ng8 +0.41
9. Be3 +0.21
... Bb7 +1.22
10. g4 +0.03
... Nf6 +1.04
11. f3 -0.98
... d6 +1.04
12. Kf2 -0.79
... Kd7 +1.04
13. g5 -0.98
... Nh5 +1.05
14. b4 -0.98
... axb4 +0.03
15. Nb5 -2.01
... Ra6 +0.03
16. c4 -1.99
... bxc3 -0.95
17. d4 -3.01
... exd4 -1.97
18. Nxc7 -5.22
... dxe3 -4.18
19. Qxe3 -7.38
... Ra7 -3.14
20. Ne8 -7.18
... Kxe8 -6.14
21. Bc4 -8.01
... Kd7 -6.14
22. f4 -8.20
... f5 -6.15
23. gxf6 -7.21
... gxf6 -6.17
24. f5 -8.22
... Bg7 -6.36
25. Ra3 -8.42
... c2 -6.40
26. a5 -15.55
... h6 -6.39
27. axb6 -14.54
... Rxa3 -6.39
28. Qxh6 -19.98
... Rxh6 -19.97
29. e5 -28.12
... Rxh3 -22.15
30. e6 -24.20
... Kc8 -22.96
6. b3 -0.19
... Qe7 +0.01
7. d3 -0.20
... Ng8 +0.22
8. Be3 +0.02
... Ra6 +0.42
9. g4 +0.04
... Nf6 +0.24
10. f3 -0.97
... d6 +0.24
11. Kf2 -0.98
... Bd7 +0.24
12. b4 -0.98
... axb4 -0.78
13. Nb5 -2.00
... b6 +0.02
14. Nxc7 +0.01
... Kd8 +5.21
15. Nb5 -1.01
... g6 +1.01
16. c3 -1.01
... bxc3 +0.03
17. d4 -2.03
... exd4 -0.99
18. Bf4 -3.05
... Bg7 -1.19
19. Qa2 -3.25
... h5 -1.21
20. Bc4 -3.08
... hxg4 -2.04
21. Ng5 -4.28
... gxf3 -3.06
22. Nxf3 -4.26
... Nxe4 -4.08
Challenge lost - no moves available
68 changes: 24 additions & 44 deletions golden-games/b8add891-a281-4569-9875-b6cce63f9338/depth-3.txt
Original file line number Diff line number Diff line change
Expand Up @@ -10,48 +10,28 @@
... cxd5 -2.99
6. Qe2 -1.99
... Qa5 -3.81
7. Ra2 -1.99
... Nh6 -3.99
8. Qe3 -1.99
... Nf5 -4.01
9. Qf4 +0.19
... d4 -3.82
10. Be2 +0.38
... d5 -3.82
11. b3 +0.19
... Bd7 -3.83
12. Ba3 -0.62
... Rc8 -3.99
13. h4 -0.60
... b5 -3.81
14. axb5 +0.39
... Rc7 -4.98
15. b4 +3.23
... Qb6 -2.80
16. Rh2 +1.41
... e6 -2.98
17. g4 +1.25
... Bd6 -7.16
18. Qg5 -3.95
... h6 -7.17
19. Qh5 -3.96
... g6 -7.98
20. gxf5 -6.96
... gxh5 -9.01
21. f4 -7.99
... Bxf4 -10.03
22. Rh3 -9.01
... exf5 -10.04
23. Rf3 -9.01
... Bxb5 -11.06
24. Rxf4 -7.66
... Re7 -10.04
25. d3 -7.02
... Bd7 -10.85
26. f3 -7.01
... Rh7 -11.04
27. b5 -7.83
... Qa5 -11.03
28. c3 -8.83
... Qxc3 -12.03
7. Qd3 -2.17
... Nh6 -4.01
8. Be2 -1.99
... e5 -3.83
9. Qe3 -2.01
... d4 -4.04
10. Qd3 -2.19
... Be7 -4.04
11. g4 -2.19
... d5 -4.24
12. h4 -2.37
... b5 -4.24
13. g5 -1.98
... Bf5 -4.44
14. Qb3 -2.18
... bxa4 -5.47
15. gxh6 -1.05
... d3 -4.45
16. hxg7 +1.00
... Rg8 -3.44
17. Bxd3 +0.82
... Rxg7 -3.64
18. Be2 -0.25
... Rg1 -4.45
Challenge lost - no moves available
58 changes: 33 additions & 25 deletions golden-games/b8add891-a281-4569-9875-b6cce63f9338/depth-4.txt
Original file line number Diff line number Diff line change
Expand Up @@ -20,30 +20,38 @@
... Qb6 +1.07
11. d5 -0.16
... Bb7 +1.05
12. Ra2 -0.98
12. Bf4 -1.00
... Rc8 +1.05
13. dxc6 -1.18
... Bxc6 +1.25
14. Bf4 -1.16
... e5 +1.23
15. Bd2 -1.96
... a6 +1.03
16. a4 -1.95
... bxa4 +0.22
17. Bc4 -2.03
... Qxb4 +0.36
18. Be6 -2.85
... Qb6 +0.56
19. Qe2 -2.03
... Rc7 +1.37
20. Qc4 -1.84
... Ng5 +1.36
21. Bxg5 -1.84
... fxg5 +1.36
22. Ke2 -2.66
... Bb5 +1.36
23. Bxd7 -7.84
... Kxd7 -6.81
24. Ra3 -11.24
... Bxc4 -11.24
13. Na2 -1.15
... cxd5 +0.87
14. exd5 -1.17
... a5 +0.24
15. bxa5 -0.97
... Qxa5 +0.85
16. c3 -3.15
... g5 +0.84
17. Kd2 -3.17
... gxf4 -1.95
18. Nxf4 -5.15
... Bh6 -2.16
19. Ke3 -5.36
... Rc7 -2.16
20. h4 -5.54
... Bxf4 -2.33
21. Kxf4 -5.53
... Ne5 -2.14
22. h5 -3.36
... Qxa3 -2.12
23. h6 -6.53
... Qa4 -2.94
24. Ke3 -10.14
... Nc4 -3.13
25. Bxc4 -4.57
... Qxc4 -3.12
26. g5 -5.60
... fxg5 -4.15
27. f4 -8.58
... gxf4 -5.38
28. Kd2 -15.41
... Qxd5 -6.21
Challenge lost - no moves available
6 changes: 5 additions & 1 deletion src/challenges/chess-simp/2024-05.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,11 @@ export class Simp_2024_05_01 implements Challenge {
isMoveAllowed: Challenge['isMoveAllowed'] = ({ board, move }) => {
// For all pieces that moved: if the piece is not a pawn, check that the piece landed above a non-empty square.
return getAllMovers(board, move).every(
({ pieceBefore, to }) => isPawn(pieceBefore) || board.at(to.s()) !== PieceEmpty
({ pieceBefore, from, to }) =>
// Pawns are always ok (this also handles the very tricky case of en passant where idk what the right answer is otherwise)
isPawn(pieceBefore) ||
// For pieces, we can check the square in the board before the move, *but* pieces can never move north
(!to.s().equals(from) && board.at(to.s()) !== PieceEmpty)
)
}
}

0 comments on commit cf7fa22

Please sign in to comment.