aboutsummaryrefslogtreecommitdiff
path: root/higgs.h
blob: 504eae6d9a12f7479345a8c28a97075d2e4932e2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
#include <vector>
#include <climits>

#define S 	5
#define SS	25

int getIndex(int x, int y);
int getX(int i);
int getY(int i);

struct Move {
	int ndir;
	int p;
	int dir;
};

class Board {
public:
	int square[SS];
	int proton[2*S];
	int neutron;
	int move_count;
public:
	void doMove( Move move );
	void undoMove( Move move, int n );
	std::vector<Move> generateMoves();
	int neutronWin();
	int pushPiece( int p, int d, bool e = false );
	void print();
	Board();
	Board( Board& );
};