1 |
689 |
jeremybenn |
#define N 8
|
2 |
|
|
#define TESTS \
|
3 |
|
|
T (0, 0, 1, 2, 3, 4, 5, 6, 7) \
|
4 |
|
|
T (1, 0, 0, 0, 0, 0, 0, 0, 0) \
|
5 |
|
|
T (2, 0, 1, 2, 3, 0, 1, 2, 3) \
|
6 |
|
|
T (3, 0, 10, 3, 8, 1, 11, 10, 2) \
|
7 |
|
|
T (4, 0, 1, 2, 3, 3, 0, 2, 1) \
|
8 |
|
|
T (5, 12, 5, 14, 9, 8, 15, 1, 7) \
|
9 |
|
|
T (6, 9, 10, 11, 8, 4, 15, 14, 12) \
|
10 |
|
|
T (7, 4, 10, 14, 9, 11, 1, 12, 11) \
|
11 |
|
|
T (8, 15, 3, 3, 8, 5, 11, 2, 10) \
|
12 |
|
|
T (9, 13, 11, 10, 15, 8, 5, 14, 8) \
|
13 |
|
|
T (10, 9, 13, 12, 14, 10, 1, 5, 14) \
|
14 |
|
|
T (11, 5, 11, 12, 6, 3, 2, 4, 15) \
|
15 |
|
|
T (12, 5, 13, 14, 8, 4, 10, 4, 12) \
|
16 |
|
|
T (13, 14, 8, 12, 3, 13, 9, 5, 4) \
|
17 |
|
|
T (14, 15, 3, 13, 6, 14, 12, 10, 0) \
|
18 |
|
|
T (15, 0, 5, 11, 7, 4, 6, 14, 1) \
|
19 |
|
|
T (16, 0, 2, 4, 6, 8, 10, 12, 14) \
|
20 |
|
|
T (17, 1, 3, 5, 7, 9, 11, 13, 15) \
|
21 |
|
|
T (18, 3, 3, 3, 3, 3, 3, 3, 3) \
|
22 |
|
|
T (19, 7, 6, 5, 4, 3, 2, 1, 0) \
|
23 |
|
|
T (20, 0, 8, 1, 9, 2, 10, 3, 11) \
|
24 |
|
|
T (21, 4, 12, 5, 13, 6, 14, 7, 15)
|
25 |
|
|
#define EXPTESTS \
|
26 |
|
|
T (116, 9, 3, 9, 4, 7, 0, 0, 6) \
|
27 |
|
|
T (117, 4, 14, 12, 8, 9, 6, 0, 10) \
|
28 |
|
|
T (118, 10, 12, 1, 3, 4, 11, 9, 2) \
|
29 |
|
|
T (119, 4, 11, 9, 5, 8, 14, 0, 2) \
|
30 |
|
|
T (120, 0, 10, 8, 6, 4, 9, 7, 5) \
|
31 |
|
|
T (121, 10, 15, 0, 4, 12, 9, 7, 3) \
|
32 |
|
|
T (122, 13, 6, 0, 7, 5, 12, 12, 2) \
|
33 |
|
|
T (123, 4, 10, 11, 15, 12, 7, 3, 8) \
|
34 |
|
|
T (124, 1, 13, 15, 9, 6, 5, 7, 4) \
|
35 |
|
|
T (125, 7, 13, 2, 5, 2, 8, 1, 6) \
|
36 |
|
|
T (126, 4, 5, 2, 12, 14, 13, 8, 6) \
|
37 |
|
|
T (127, 4, 10, 2, 7, 11, 15, 9, 0) \
|
38 |
|
|
T (128, 14, 8, 12, 10, 13, 3, 11, 2) \
|
39 |
|
|
T (129, 10, 8, 14, 9, 5, 1, 15, 7) \
|
40 |
|
|
T (130, 12, 2, 9, 13, 5, 14, 1, 15) \
|
41 |
|
|
T (131, 10, 4, 1, 14, 11, 15, 9, 2) \
|
42 |
|
|
T (132, 9, 12, 7, 4, 2, 1, 0, 9) \
|
43 |
|
|
T (133, 11, 15, 4, 10, 3, 12, 13, 5) \
|
44 |
|
|
T (134, 1, 5, 6, 13, 14, 15, 3, 10) \
|
45 |
|
|
T (135, 0, 14, 6, 10, 1, 13, 3, 2) \
|
46 |
|
|
T (136, 2, 11, 1, 5, 12, 13, 3, 5) \
|
47 |
|
|
T (137, 7, 11, 4, 1, 12, 10, 14, 10) \
|
48 |
|
|
T (138, 3, 6, 7, 13, 11, 15, 10, 0) \
|
49 |
|
|
T (139, 10, 8, 7, 14, 1, 11, 0, 13) \
|
50 |
|
|
T (140, 5, 3, 13, 11, 8, 5, 12, 6) \
|
51 |
|
|
T (141, 15, 2, 12, 13, 10, 8, 5, 0) \
|
52 |
|
|
T (142, 13, 9, 10, 2, 11, 3, 4, 1) \
|
53 |
|
|
T (143, 2, 14, 6, 5, 1, 8, 15, 0) \
|
54 |
|
|
T (144, 12, 9, 14, 10, 1, 3, 11, 13) \
|
55 |
|
|
T (145, 12, 13, 11, 2, 5, 6, 4, 8) \
|
56 |
|
|
T (146, 5, 0, 2, 1, 6, 8, 15, 13) \
|
57 |
|
|
T (147, 8, 7, 1, 3, 5, 11, 14, 15) \
|
58 |
|
|
T (148, 0, 9, 2, 15, 3, 1, 8, 10) \
|
59 |
|
|
T (149, 4, 14, 11, 6, 8, 5, 12, 7) \
|
60 |
|
|
T (150, 5, 9, 10, 12, 14, 15, 2, 7) \
|
61 |
|
|
T (151, 11, 6, 5, 7, 11, 14, 2, 1) \
|
62 |
|
|
T (152, 13, 1, 7, 4, 6, 8, 15, 9) \
|
63 |
|
|
T (153, 10, 12, 9, 1, 6, 7, 8, 15) \
|
64 |
|
|
T (154, 8, 4, 5, 1, 3, 0, 7, 13) \
|
65 |
|
|
T (155, 13, 9, 3, 4, 10, 1, 15, 7) \
|
66 |
|
|
T (156, 13, 8, 2, 7, 0, 6, 3, 6) \
|
67 |
|
|
T (157, 15, 15, 13, 6, 0, 5, 14, 4) \
|
68 |
|
|
T (158, 13, 1, 2, 2, 7, 9, 2, 6) \
|
69 |
|
|
T (159, 5, 12, 10, 13, 6, 1, 4, 7) \
|
70 |
|
|
T (160, 0, 2, 9, 1, 5, 11, 14, 11) \
|
71 |
|
|
T (161, 14, 6, 5, 10, 3, 2, 15, 4) \
|
72 |
|
|
T (162, 3, 10, 0, 1, 13, 14, 11, 15) \
|
73 |
|
|
T (163, 13, 7, 5, 9, 5, 0, 11, 4) \
|
74 |
|
|
T (164, 2, 11, 1, 12, 3, 13, 4, 9) \
|
75 |
|
|
T (165, 1, 0, 10, 11, 5, 13, 4, 3) \
|
76 |
|
|
T (166, 3, 9, 1, 12, 15, 14, 10, 5) \
|
77 |
|
|
T (167, 3, 10, 11, 14, 5, 1, 8, 12) \
|
78 |
|
|
T (168, 10, 15, 5, 14, 4, 13, 6, 3) \
|
79 |
|
|
T (169, 1, 8, 6, 4, 11, 13, 7, 10) \
|
80 |
|
|
T (170, 8, 7, 1, 15, 11, 9, 0, 3) \
|
81 |
|
|
T (171, 4, 0, 11, 7, 1, 15, 3, 13) \
|
82 |
|
|
T (172, 14, 7, 3, 4, 9, 11, 0, 6) \
|
83 |
|
|
T (173, 7, 3, 11, 4, 8, 2, 10, 15) \
|
84 |
|
|
T (174, 7, 9, 14, 2, 0, 5, 13, 3) \
|
85 |
|
|
T (175, 4, 8, 5, 9, 3, 11, 1, 14) \
|
86 |
|
|
T (176, 13, 12, 3, 3, 1, 4, 8, 5) \
|
87 |
|
|
T (177, 7, 12, 9, 13, 10, 4, 5, 8) \
|
88 |
|
|
T (178, 14, 3, 12, 7, 2, 6, 5, 5) \
|
89 |
|
|
T (179, 7, 0, 8, 6, 2, 14, 12, 15) \
|
90 |
|
|
T (180, 2, 12, 0, 4, 1, 15, 11, 10) \
|
91 |
|
|
T (181, 0, 7, 5, 12, 15, 10, 14, 3) \
|
92 |
|
|
T (182, 3, 10, 2, 5, 11, 6, 13, 14) \
|
93 |
|
|
T (183, 3, 2, 7, 11, 0, 13, 8, 10) \
|
94 |
|
|
T (184, 0, 12, 15, 1, 9, 2, 11, 4) \
|
95 |
|
|
T (185, 11, 15, 8, 10, 9, 1, 13, 3) \
|
96 |
|
|
T (186, 12, 13, 15, 12, 3, 9, 5, 7) \
|
97 |
|
|
T (187, 4, 10, 5, 6, 1, 11, 0, 11) \
|
98 |
|
|
T (188, 11, 6, 7, 9, 0, 8, 14, 8) \
|
99 |
|
|
T (189, 1, 15, 6, 9, 12, 6, 7, 14) \
|
100 |
|
|
T (190, 1, 5, 6, 11, 12, 13, 3, 0) \
|
101 |
|
|
T (191, 0, 8, 15, 13, 12, 6, 1, 4) \
|
102 |
|
|
T (192, 12, 15, 8, 4, 2, 0, 9, 5) \
|
103 |
|
|
T (193, 14, 5, 13, 10, 12, 11, 0, 1) \
|
104 |
|
|
T (194, 12, 1, 9, 8, 10, 9, 0, 2) \
|
105 |
|
|
T (195, 11, 0, 13, 4, 6, 2, 14, 15) \
|
106 |
|
|
T (196, 0, 10, 6, 2, 12, 4, 9, 13) \
|
107 |
|
|
T (197, 7, 12, 8, 10, 1, 0, 5, 0) \
|
108 |
|
|
T (198, 12, 13, 0, 5, 3, 14, 11, 4) \
|
109 |
|
|
T (199, 9, 1, 4, 14, 10, 12, 15, 6) \
|
110 |
|
|
T (200, 3, 12, 13, 6, 14, 2, 1, 6) \
|
111 |
|
|
T (201, 5, 14, 8, 10, 1, 12, 2, 0) \
|
112 |
|
|
T (202, 5, 8, 2, 7, 4, 15, 14, 2) \
|
113 |
|
|
T (203, 14, 13, 10, 9, 11, 15, 7, 8) \
|
114 |
|
|
T (204, 12, 13, 14, 2, 4, 9, 5, 7) \
|
115 |
|
|
T (205, 0, 7, 5, 4, 7, 13, 6, 8) \
|
116 |
|
|
T (206, 7, 0, 15, 6, 12, 2, 5, 4) \
|
117 |
|
|
T (207, 8, 6, 0, 1, 1, 11, 1, 9) \
|
118 |
|
|
T (208, 11, 6, 14, 9, 5, 3, 7, 13) \
|
119 |
|
|
T (209, 12, 3, 15, 9, 1, 0, 8, 13) \
|
120 |
|
|
T (210, 11, 1, 9, 8, 7, 6, 12, 2) \
|
121 |
|
|
T (211, 10, 9, 2, 6, 8, 11, 0, 4) \
|
122 |
|
|
T (212, 10, 13, 15, 9, 6, 15, 14, 10) \
|
123 |
|
|
T (213, 9, 5, 8, 3, 4, 7, 11, 4) \
|
124 |
|
|
T (214, 1, 2, 13, 5, 8, 4, 3, 6) \
|
125 |
|
|
T (215, 8, 3, 2, 4, 9, 14, 12, 13) \
|
126 |
|
|
T (216, 5, 7, 8, 15, 3, 1, 10, 4) \
|
127 |
|
|
T (217, 2, 9, 3, 2, 14, 11, 5, 7) \
|
128 |
|
|
T (218, 15, 6, 4, 10, 14, 3, 13, 2) \
|
129 |
|
|
T (219, 0, 8, 14, 5, 15, 7, 10, 1) \
|
130 |
|
|
T (220, 14, 0, 6, 10, 8, 2, 7, 4) \
|
131 |
|
|
T (221, 15, 13, 3, 14, 11, 2, 14, 6) \
|
132 |
|
|
T (222, 8, 2, 10, 13, 1, 0, 4, 11) \
|
133 |
|
|
T (223, 7, 15, 2, 9, 1, 12, 11, 3) \
|
134 |
|
|
T (224, 13, 15, 3, 12, 15, 7, 0, 8) \
|
135 |
|
|
T (225, 0, 2, 1, 11, 14, 3, 9, 14) \
|
136 |
|
|
T (226, 12, 14, 3, 15, 8, 5, 1, 7) \
|
137 |
|
|
T (227, 0, 5, 13, 8, 4, 2, 1, 3)
|