fork download
  1. //the latest
  2. //the latest
  3. /* package whatever; // don't place package name! */
  4. import java.util.*;
  5. import java.lang.*;
  6. import java.io.*;
  7.  
  8.  
  9.  
  10. /* Name of the class has to be "Main" only if the class is public. */
  11. class Idone
  12. {
  13. public static void main (String[] args) throws java.lang.Exception
  14. {
  15. int[][][] Box = new int[9][9][11] ;
  16. for(int i= 0; i<9;i++) {
  17. for(int j= 0;j<9;j++) {
  18. Box[i][j][9]=0;
  19. Box[i][j][10]=9;
  20. for(int k = 0; k<9;k++) {
  21. Box[i][j][k] = 1;
  22. }//for k
  23. }//for j
  24. }//for i
  25. /*assign( Box ,0 ,2 ,5 );
  26. assign( Box , 0, 5,1 );
  27. assign( Box , 0, 7,8);
  28. assign( Box , 0, 8,6 );
  29. assign( Box , 1, 3,2 );
  30. assign( Box , 1,8 ,3 );
  31. assign( Box , 2, 0,3 );
  32. assign( Box , 2, 4,7 );
  33. assign( Box , 3, 1,1 );
  34. assign( Box , 3,3 ,4 );
  35. assign( Box , 3,5 ,6 );
  36. assign( Box , 3, 8, 7);
  37. assign( Box , 4, 2,3 );
  38. assign( Box , 4, 6,5 );
  39. assign( Box , 5,0 ,7 );
  40. assign( Box , 5,3 ,1 );
  41. assign( Box , 5,5 ,3 );
  42. assign( Box , 5, 7, 4);
  43. assign( Box , 6,4 ,6 );
  44. assign( Box , 6,8 ,9 );
  45. assign( Box , 7,0 ,2 );
  46. assign( Box , 7,5 ,7 );
  47. assign( Box , 8,0 ,5 );
  48. assign( Box , 8,1 ,8 );
  49. assign( Box , 8, 3, 9);
  50. assign( Box , 8, 6, 2);*/
  51.  
  52. /*assign( Box ,0 ,0 ,3 );
  53. assign( Box , 0, 1,7 );
  54. assign( Box , 0, 3,5);
  55. assign( Box , 0, 4,1 );
  56. assign( Box , 0, 5,8 );
  57. assign( Box , 1,8 ,9 );
  58. assign( Box , 2, 1,6 );
  59. assign( Box , 2, 2,4 );
  60. assign( Box , 2, 3,9 );
  61. assign( Box , 2,6 ,8 );
  62. assign( Box , 3,0 ,1 );
  63. assign( Box , 3, 4, 5);
  64. assign( Box , 3, 8,4 );
  65. assign( Box , 4, 2,2 );
  66. assign( Box , 4,6 ,7 );
  67. assign( Box , 5,0 ,9 );
  68. assign( Box , 5,4 ,3 );
  69. assign( Box , 5, 8, 2);
  70. assign( Box , 6,2 ,3 );
  71. assign( Box , 6,5 ,7 );
  72. assign( Box , 6,6 ,9 );
  73. assign( Box , 6,7 ,5 );
  74. assign( Box , 7,0 ,4 );
  75. assign( Box , 8,3 ,8 );
  76. assign( Box , 8, 4, 2);
  77. assign( Box , 8, 5, 6);
  78. assign( Box ,8,7,4);
  79. assign( Box ,8,8,3);*/
  80. /*
  81. //Ozone
  82. assign( Box ,0 ,1 ,7 );
  83. assign( Box , 0, 3,9 );
  84. assign( Box , 1, 2,3 );
  85. assign( Box , 1, 4,4 );
  86. assign( Box , 1, 8,7 );
  87. assign( Box , 2,2 ,2 );
  88. assign( Box , 2, 4,7 );
  89. assign( Box , 2, 5,1 );
  90. assign( Box , 2, 6,8 );
  91. assign( Box , 2,7 ,6 );
  92. assign( Box , 3,2 ,6 );
  93. assign( Box , 3, 8, 4);
  94. assign( Box , 4, 1,5 );
  95. assign( Box , 4, 2,4 );
  96. assign( Box , 4,4 ,8 );
  97. assign( Box , 4,6 ,9 );
  98. assign( Box , 4,7 ,3 );
  99. assign( Box , 5, 0, 3);
  100. assign( Box , 5,6 ,7 );
  101. assign( Box , 6,1 ,3 );
  102. assign( Box , 6,2 ,7 );
  103. assign( Box , 6,3 ,6 );
  104. assign( Box , 6,4 ,2 );
  105. assign( Box , 6,6 ,1 );
  106. assign( Box , 7, 0, 9);
  107. assign( Box , 7, 4, 5);
  108. assign( Box ,7,6,6);
  109. assign( Box ,8,5,7);
  110. assign( Box ,8,7,2);*/
  111.  
  112. /*assign( Box ,0 ,5 ,3 );
  113. assign( Box , 0, 6,5 );
  114. assign( Box , 0, 7,1 );
  115. assign( Box , 0, 8,4 );
  116. assign( Box , 1, 3,4 );
  117. assign( Box , 1,8 ,8 );
  118. assign( Box , 2, 3,6 );
  119. assign( Box , 2, 4,7 );
  120. assign( Box , 2, 8,2 );
  121. assign( Box , 3,1 ,8 );
  122. assign( Box , 3,2 ,1 );
  123. assign( Box , 3, 8, 5);
  124. assign( Box , 4, 2,3 );
  125. assign( Box , 4, 6,2 );
  126. assign( Box , 5,0 ,2 );
  127. assign( Box , 5,6 ,9 );
  128. assign( Box , 5,7 ,6 );
  129. assign( Box , 6, 0, 5);
  130. assign( Box , 6,4 ,1 );
  131. assign( Box , 6,5 ,9 );
  132. assign( Box , 7,0 ,9 );
  133. assign( Box , 7,5 ,7 );
  134. assign( Box , 8,0 ,1 );
  135. assign( Box , 8,1 ,7 );
  136. assign( Box , 8, 2, 6);
  137. assign( Box , 8, 3, 5);*/
  138.  
  139. /*assign( Box ,0 ,2,6 );
  140. assign( Box , 0,4 ,1 );
  141. assign( Box , 0,6 ,8 );
  142. assign( Box , 0,8 ,3 );
  143. assign( Box , 1,1 ,7 );
  144. assign( Box , 1,4 ,2 );
  145. assign( Box , 2,0 ,8 );
  146. assign( Box , 2,5 ,4 );
  147. assign( Box , 2,8 ,5 );
  148. assign( Box , 3,3 ,5 );
  149. assign( Box , 3,6 ,4 );
  150. assign( Box , 4,0 ,5 );
  151. assign( Box , 4,1 ,4 );
  152. assign( Box , 4,7 ,3 );
  153. assign( Box ,4 ,8 ,2 );
  154. assign( Box , 5,2 ,7 );
  155. assign( Box , 5,5 ,8 );
  156. assign( Box , 6,0 ,6 );
  157. assign( Box , 6,3 ,7 );
  158. assign( Box , 6, 8,1 );
  159. assign( Box , 7, 4,8 );
  160. assign( Box , 7, 7,9 );
  161. assign( Box , 8, 0,2 );
  162. assign( Box , 8, 2, 4);
  163. assign( Box , 8, 4,5 );
  164. assign( Box ,8 , 6,6 );*/
  165.  
  166. assign(Box,0,3,4);
  167. assign(Box,0,4,8);
  168. assign(Box,0,6,6);
  169. assign(Box,0,7,2);
  170. assign(Box,1,4,2);
  171. assign(Box,1,8,9);
  172. assign(Box,2,2,3);
  173. assign(Box,2,5,7);
  174. assign(Box,2,8,5);
  175. assign(Box,3,0,9);
  176. assign(Box,3,5,8);
  177. assign(Box,3,6,5);
  178. assign(Box,4,8,7);
  179. assign(Box,4,0,1);
  180. assign(Box,4,1,4);
  181. assign(Box,4,7,8);
  182. assign(Box,5,2,7);
  183. assign(Box,5,3,2);
  184. assign(Box,5,8,1);
  185. assign(Box,6,0,2);
  186. assign(Box,6,3,8);
  187. assign(Box,6,6,3);
  188. assign(Box,7,0,4);
  189. assign(Box,7,4,6);
  190. assign(Box,8,1,9);
  191. assign(Box,8,2,8);
  192. assign(Box,8,4,5);
  193. assign(Box,8,5,4);
  194.  
  195. /*assign(Box,0,1,1);
  196. assign(Box,0,2,8);
  197. assign(Box,0,5,4);
  198. assign(Box,0,6,3);
  199. assign(Box,1,0,3);
  200. assign(Box,1,5,5);
  201. assign(Box,1,6,4);
  202. assign(Box,2,0,7);
  203. assign(Box,2,4,2);
  204. assign(Box,2,7,8);
  205. assign(Box,2,8,1);
  206. assign(Box,3,7,5);
  207. assign(Box,3,8,4);
  208. assign(Box,4,2,4);
  209. assign(Box,4,6,9);
  210. assign(Box,5,0,8);
  211. assign(Box,5,1,5);
  212. assign(Box,6,0,2);
  213. assign(Box,6,1,7);
  214. assign(Box,6,4,9);
  215. assign(Box,6,8,3);
  216. assign(Box,7,2,1);
  217. assign(Box,7,3,8);
  218. assign(Box,7,8,7);
  219. assign(Box,8,2,9);
  220. assign(Box,8,3,7);
  221. assign(Box,8,6,5);
  222. assign(Box,8,7,1);
  223. */
  224. for (int i = 0 ; i < 10; i++){
  225. is_unique(Box);
  226. }
  227. print_big_box(Box);
  228. //is_solved(Box);
  229. System.out.println("_______________");
  230. for (int i = 0 ; i <9; i++){
  231. print_possibilities_of_specific_value(Box,7);
  232. //print_possibilities_of_specific_square(Box,0,0);
  233. print_possibilities_of_each_square(Box);
  234. }
  235. /////is_unique(Box);
  236. //System.out.println("_______________");
  237. //print_big_box(Box);
  238. }
  239. public static void print_possibilities_of_each_square(int[][][] B_Box){
  240. // print the possibility of a certain square
  241. // System.out.println(check_same_big_box(B_Box,1,5,1));
  242.  
  243. for(int i = 0; i<9 ; i++){
  244. if (i%3==0){
  245. System.out.println("____________________");
  246. }
  247. for(int j = 0;j<9 ; j++){
  248. if (j%3==0){
  249. System.out.print("|");
  250. }
  251. System.out.print(B_Box[i][j][10]+ " ");
  252. }
  253. System.out.println();
  254.  
  255.  
  256. }
  257. System.out.println();
  258. }
  259. public static void print_possibilities_of_specific_value(int[][][] B_Box, int v ){
  260. // print the possibility of a certain square
  261. // System.out.println(check_same_big_box(B_Box,1,5,1));
  262.  
  263. for(int i = 0; i<9 ; i++){
  264. if (i%3==0){
  265. System.out.println("____________________");
  266. }
  267. for(int j = 0;j<9 ; j++){
  268. if (j%3==0){
  269. System.out.print("|");
  270. }
  271. System.out.print(B_Box[i][j][v-1]+ " ");
  272. }
  273. System.out.println();
  274.  
  275.  
  276. }
  277. System.out.println();
  278. }
  279. public static void print_possibilities_of_specific_square(int[][][] B_Box, int r, int c){
  280. // print the possibility of a certain square
  281.  
  282. for(int i = 0; i<9 ; i++){
  283. System.out.print(B_Box[r][c][i]+ " ");
  284.  
  285. }
  286. System.out.println();
  287. }
  288. public static void print_big_box(int[][][] B_Box){
  289.  
  290. for(int i = 0; i<9 ; i++){
  291. for(int j = 0; j<9 ; j++){
  292. System.out.print(B_Box[i][j][9] + " ");
  293. }//for j
  294.  
  295. System.out.println();
  296. }//for i
  297. }//print_big_box()
  298.  
  299. public static void change_marks_same_big_box(int[][][] B_Box, int r,int c, int val) {
  300.  
  301. for(int i = r - r%3; i<3+(r - r%3) ; i++){
  302. for(int j = c - c%3; j<3+(c - c%3) ; j++){
  303.  
  304. if ( (B_Box[i][j][9] == 0) && ( B_Box[i][j][10]>1) && (B_Box[i][j][val-1]==1)){
  305. B_Box[i][j][val-1]=0;
  306. B_Box[i][j][10]--;
  307. /* if( B_Box[i][j][10]==1){
  308. for (int a = 0 ; a < 9 ; a++) {
  309. if ( B_Box[i][j][a]==1) {
  310.  
  311. assign(B_Box,i,j,a+1);
  312. }//if
  313. }//for a
  314. }*///if
  315. //check_small_square_in_big_square(BBBox,b_b,i);
  316.  
  317. }//if
  318. }//for j
  319. }//for i
  320. }//change_marks_same_big_box
  321.  
  322. public static void change_marks_same_row(int[][][] B_Box, int r,int c, int val) {
  323.  
  324.  
  325. for(int j = 0; j<9 ; j++){
  326.  
  327. if ( (B_Box[r][j][9] == 0) && ( B_Box[r][j][10]>1)&& (B_Box[r][j][val-1]==1)){
  328. B_Box[r][j][val-1]=0;
  329. B_Box[r][j][10]--;
  330. /* if( B_Box[r][j][10]==1){
  331. for (int a = 0 ; a < 9 ; a++) {
  332. if ( B_Box[r][j][a]==1) {
  333.  
  334. assign(B_Box,r,j,a+1);
  335. }//if
  336. }//for a
  337. }*///if
  338. //check_small_square_in_big_square(BBBox,b_b,i);
  339.  
  340. }//if
  341. }//for j
  342.  
  343. }//change_marks_same_row
  344.  
  345. public static void change_marks_same_column(int[][][] B_Box, int r,int c, int val) {
  346.  
  347.  
  348. for(int i = 0; i<9 ; i++){
  349.  
  350. if ( (B_Box[i][c][9] == 0) && ( B_Box[i][c][10]>1)&& (B_Box[i][c][val-1]==1)){
  351. B_Box[i][c][val-1]=0;
  352. B_Box[i][c][10]--;
  353. /* if( B_Box[i][c][10]==1){
  354. for (int a = 0 ; a < 9 ; a++) {
  355. if ( B_Box[i][c][a]==1) {
  356.  
  357. assign(B_Box,i,c,a+1);
  358. }//if
  359. }//for a
  360. }*/
  361. //if
  362. //check_small_square_in_big_square(BBBox,b_b,i);
  363.  
  364. }//if
  365. }//for j
  366.  
  367. }//change_marks_same_column
  368.  
  369. public static int check_same_big_box(int[][][] B_Box, int r,int c, int val) {
  370. int cnts=0;
  371. int cntr=0;
  372. int cntc=0;
  373. int cnt=0;
  374. int x=-1;
  375. int y=-1;
  376. int u=-1;
  377. int v=-1;
  378.  
  379. for(int i = r - r%3; i<3+(r - r%3) ; i++){
  380. for(int j = c - c%3; j<3+(c - c%3) ; j++){
  381.  
  382. if ( (B_Box[i][j][9] == 0) &&(B_Box[i][j][val-1]==1)&&(B_Box[r][c][val-1]==1)){
  383. cnts++;
  384. // if((i==0)&&(j==3) &&(val==3))
  385. // {System.out.println("hiiiii cnts: " + cnts + "r: "+i +"col: "+j );
  386. // }
  387. if(cnts==1){
  388. x=i;
  389. y=j;
  390. }
  391. if(cnts==2){
  392. u=i;
  393. v=j;
  394. }
  395.  
  396. }//if
  397.  
  398. }//for j
  399. }//for i
  400. if(cnts>0){
  401. for(int i = 0; i<9;i++){
  402. if ( (B_Box[i][c][9] == 0) &&(B_Box[i][c][val-1]==1)&&(B_Box[r][c][val-1]==1)){
  403. cntc++;
  404.  
  405. }//if
  406. }//for i
  407.  
  408. if (cntc>0){
  409. for(int j = 0;j<9;j++){
  410. if ( (B_Box[r][j][9] == 0) &&(B_Box[r][j][val-1]==1)&&(B_Box[r][c][val-1]==1)){
  411. cntr++;
  412.  
  413. }//if
  414. }//for i
  415. }//if cntc
  416.  
  417. }//if
  418. if(cnts==2){
  419. //System.out.println("hiiiiiiiiiiiii");
  420. if(y==v){
  421. for(int i=0;i<9;i++){
  422. if((i!=x)&&(i!=u)&&(B_Box[i][y][val-1]==1)){
  423. // if((i==0)&&(y==3) &&(val==3))
  424. // {System.out.println("hiiiiiMarcel" + cnts);
  425. // }
  426. B_Box[i][y][val-1]=0;
  427. B_Box[i][y][10]--;
  428. }
  429. }
  430. }
  431. if(x==u){
  432. for(int i=0;i<9;i++){
  433. if((i!=y)&&(i!=v)&&(B_Box[x][i][val-1]==1)){
  434. B_Box[x][i][val-1]=0;
  435. B_Box[x][i][10]--;
  436. }
  437. }
  438. }
  439. }
  440. // if((r==0)&&(c==3) &&(val==3))
  441. //// {
  442. //System.out.println("cnts: "+ cnts + " cntc: "+ cntc+" cntr: "+ cntr);
  443. //}
  444. if ((cnts==1)||(cntc==1)||(cntr==1)){
  445. cnt=1;
  446. }
  447. return cnt;
  448. }//check_same_big_box
  449.  
  450. public static void is_unique(int[][][] B_Box) {
  451.  
  452. for(int m = 0; m<9 ; m++){
  453. for(int n = 0; n<9 ; n++){
  454. // if((m==0)&&(n==3)){
  455. // System.out.println("check_same_big_box("+m+","+n+","+6+")" +B_Box[m][n][10]+" "+B_Box[m][n][9] + " "+check_same_big_box(B_Box,m,n,3));
  456. // }//if
  457.  
  458. if((B_Box[m][n][9] == 0) && ( B_Box[m][n][10]>1)){
  459. for (int a = 1 ; a < 10 ; a++) {
  460. if(check_same_big_box(B_Box,m,n,a)==1){
  461.  
  462. assign(B_Box,m,n,a);
  463.  
  464.  
  465. }//if
  466. }//for a
  467.  
  468. }//if
  469. if((B_Box[m][n][9] == 0) && ( B_Box[m][n][10]==1)){
  470. for (int a = 1 ; a < 10 ; a++) {
  471. if(B_Box[m][n][a-1]==1){
  472.  
  473. assign(B_Box,m,n,a);
  474.  
  475.  
  476. }//if
  477. }//for a
  478.  
  479. }//if
  480. }//for j
  481. }//for //i
  482.  
  483. }
  484.  
  485. public static void is_solved(int[][][] B_Box) {
  486.  
  487. for(int i = 0; i<9 ; i++){
  488. for(int j = 0; j<9 ; j++){
  489.  
  490. if((B_Box[i][j][9] == 0) && ( B_Box[i][j][10]==1)){
  491. for (int a = 0 ; a < 9 ; a++) {
  492. if ( B_Box[i][j][a]==1) {
  493.  
  494. assign(B_Box,i,j,a+1);
  495. }//if
  496. }//fora
  497. }//if
  498. }//forj
  499. }//for i
  500.  
  501. }
  502.  
  503.  
  504. public static void assign(int[][][] B_Box, int r,int c, int val) {
  505.  
  506. B_Box[r][c][9]= val;
  507. B_Box[r][c][10]=1;
  508. B_Box[r][c][val-1]=1;
  509. for (int i = 0; i < 9; i++){
  510. if(i!=(val-1)){
  511. B_Box[r][c][i]=0;
  512. }//if
  513. }//for i
  514. change_marks_same_big_box(B_Box,r,c,val);
  515. change_marks_same_row(B_Box,r,c,val);
  516. change_marks_same_column(B_Box,r,c,val);
  517. is_unique(B_Box);
  518. //is_solved(BBBox);
  519.  
  520. }
  521.  
  522. }
Success #stdin #stdout 0.19s 30056KB
stdin
Standard input is empty
stdout
0 0 9 4 8 0 6 2 3 
0 0 4 0 2 3 0 0 9 
0 2 3 0 0 7 0 0 5 
9 0 0 0 0 8 5 0 0 
1 4 0 0 3 0 0 8 7 
0 0 7 2 0 0 0 0 1 
2 0 0 8 0 0 3 0 0 
4 0 0 0 6 2 0 0 8 
0 9 8 0 5 4 0 0 0 
_______________
____________________
|1 1 0 |0 0 0 |0 0 0 
|0 0 0 |0 0 0 |1 1 0 
|0 0 0 |0 0 1 |0 0 0 
____________________
|0 0 0 |1 1 0 |0 0 0 
|0 0 0 |0 0 0 |0 0 1 
|0 0 1 |0 0 0 |0 0 0 
____________________
|0 1 0 |0 1 0 |0 1 0 
|0 1 0 |1 0 0 |1 1 0 
|1 0 0 |1 0 0 |1 1 0 

____________________
|2 3 1 |1 1 2 |1 1 1 
|3 4 1 |3 1 1 |3 2 1 
|2 1 1 |3 2 1 |3 2 1 
____________________
|1 2 2 |2 3 1 |1 3 3 
|1 1 3 |2 1 3 |2 1 1 
|4 4 1 |1 2 3 |2 4 1 
____________________
|1 3 3 |1 3 2 |1 6 2 
|1 3 2 |4 1 1 |3 4 1 
|3 1 1 |3 1 1 |3 3 2 

____________________
|1 1 0 |0 0 0 |0 0 0 
|0 0 0 |0 0 0 |1 1 0 
|0 0 0 |0 0 1 |0 0 0 
____________________
|0 0 0 |1 1 0 |0 0 0 
|0 0 0 |0 0 0 |0 0 1 
|0 0 1 |0 0 0 |0 0 0 
____________________
|0 1 0 |0 1 0 |0 1 0 
|0 1 0 |1 0 0 |1 1 0 
|1 0 0 |1 0 0 |1 1 0 

____________________
|2 3 1 |1 1 2 |1 1 1 
|3 4 1 |3 1 1 |3 2 1 
|2 1 1 |3 2 1 |3 2 1 
____________________
|1 2 2 |2 3 1 |1 3 3 
|1 1 3 |2 1 3 |2 1 1 
|4 4 1 |1 2 3 |2 4 1 
____________________
|1 3 3 |1 3 2 |1 6 2 
|1 3 2 |4 1 1 |3 4 1 
|3 1 1 |3 1 1 |3 3 2 

____________________
|1 1 0 |0 0 0 |0 0 0 
|0 0 0 |0 0 0 |1 1 0 
|0 0 0 |0 0 1 |0 0 0 
____________________
|0 0 0 |1 1 0 |0 0 0 
|0 0 0 |0 0 0 |0 0 1 
|0 0 1 |0 0 0 |0 0 0 
____________________
|0 1 0 |0 1 0 |0 1 0 
|0 1 0 |1 0 0 |1 1 0 
|1 0 0 |1 0 0 |1 1 0 

____________________
|2 3 1 |1 1 2 |1 1 1 
|3 4 1 |3 1 1 |3 2 1 
|2 1 1 |3 2 1 |3 2 1 
____________________
|1 2 2 |2 3 1 |1 3 3 
|1 1 3 |2 1 3 |2 1 1 
|4 4 1 |1 2 3 |2 4 1 
____________________
|1 3 3 |1 3 2 |1 6 2 
|1 3 2 |4 1 1 |3 4 1 
|3 1 1 |3 1 1 |3 3 2 

____________________
|1 1 0 |0 0 0 |0 0 0 
|0 0 0 |0 0 0 |1 1 0 
|0 0 0 |0 0 1 |0 0 0 
____________________
|0 0 0 |1 1 0 |0 0 0 
|0 0 0 |0 0 0 |0 0 1 
|0 0 1 |0 0 0 |0 0 0 
____________________
|0 1 0 |0 1 0 |0 1 0 
|0 1 0 |1 0 0 |1 1 0 
|1 0 0 |1 0 0 |1 1 0 

____________________
|2 3 1 |1 1 2 |1 1 1 
|3 4 1 |3 1 1 |3 2 1 
|2 1 1 |3 2 1 |3 2 1 
____________________
|1 2 2 |2 3 1 |1 3 3 
|1 1 3 |2 1 3 |2 1 1 
|4 4 1 |1 2 3 |2 4 1 
____________________
|1 3 3 |1 3 2 |1 6 2 
|1 3 2 |4 1 1 |3 4 1 
|3 1 1 |3 1 1 |3 3 2 

____________________
|1 1 0 |0 0 0 |0 0 0 
|0 0 0 |0 0 0 |1 1 0 
|0 0 0 |0 0 1 |0 0 0 
____________________
|0 0 0 |1 1 0 |0 0 0 
|0 0 0 |0 0 0 |0 0 1 
|0 0 1 |0 0 0 |0 0 0 
____________________
|0 1 0 |0 1 0 |0 1 0 
|0 1 0 |1 0 0 |1 1 0 
|1 0 0 |1 0 0 |1 1 0 

____________________
|2 3 1 |1 1 2 |1 1 1 
|3 4 1 |3 1 1 |3 2 1 
|2 1 1 |3 2 1 |3 2 1 
____________________
|1 2 2 |2 3 1 |1 3 3 
|1 1 3 |2 1 3 |2 1 1 
|4 4 1 |1 2 3 |2 4 1 
____________________
|1 3 3 |1 3 2 |1 6 2 
|1 3 2 |4 1 1 |3 4 1 
|3 1 1 |3 1 1 |3 3 2 

____________________
|1 1 0 |0 0 0 |0 0 0 
|0 0 0 |0 0 0 |1 1 0 
|0 0 0 |0 0 1 |0 0 0 
____________________
|0 0 0 |1 1 0 |0 0 0 
|0 0 0 |0 0 0 |0 0 1 
|0 0 1 |0 0 0 |0 0 0 
____________________
|0 1 0 |0 1 0 |0 1 0 
|0 1 0 |1 0 0 |1 1 0 
|1 0 0 |1 0 0 |1 1 0 

____________________
|2 3 1 |1 1 2 |1 1 1 
|3 4 1 |3 1 1 |3 2 1 
|2 1 1 |3 2 1 |3 2 1 
____________________
|1 2 2 |2 3 1 |1 3 3 
|1 1 3 |2 1 3 |2 1 1 
|4 4 1 |1 2 3 |2 4 1 
____________________
|1 3 3 |1 3 2 |1 6 2 
|1 3 2 |4 1 1 |3 4 1 
|3 1 1 |3 1 1 |3 3 2 

____________________
|1 1 0 |0 0 0 |0 0 0 
|0 0 0 |0 0 0 |1 1 0 
|0 0 0 |0 0 1 |0 0 0 
____________________
|0 0 0 |1 1 0 |0 0 0 
|0 0 0 |0 0 0 |0 0 1 
|0 0 1 |0 0 0 |0 0 0 
____________________
|0 1 0 |0 1 0 |0 1 0 
|0 1 0 |1 0 0 |1 1 0 
|1 0 0 |1 0 0 |1 1 0 

____________________
|2 3 1 |1 1 2 |1 1 1 
|3 4 1 |3 1 1 |3 2 1 
|2 1 1 |3 2 1 |3 2 1 
____________________
|1 2 2 |2 3 1 |1 3 3 
|1 1 3 |2 1 3 |2 1 1 
|4 4 1 |1 2 3 |2 4 1 
____________________
|1 3 3 |1 3 2 |1 6 2 
|1 3 2 |4 1 1 |3 4 1 
|3 1 1 |3 1 1 |3 3 2 

____________________
|1 1 0 |0 0 0 |0 0 0 
|0 0 0 |0 0 0 |1 1 0 
|0 0 0 |0 0 1 |0 0 0 
____________________
|0 0 0 |1 1 0 |0 0 0 
|0 0 0 |0 0 0 |0 0 1 
|0 0 1 |0 0 0 |0 0 0 
____________________
|0 1 0 |0 1 0 |0 1 0 
|0 1 0 |1 0 0 |1 1 0 
|1 0 0 |1 0 0 |1 1 0 

____________________
|2 3 1 |1 1 2 |1 1 1 
|3 4 1 |3 1 1 |3 2 1 
|2 1 1 |3 2 1 |3 2 1 
____________________
|1 2 2 |2 3 1 |1 3 3 
|1 1 3 |2 1 3 |2 1 1 
|4 4 1 |1 2 3 |2 4 1 
____________________
|1 3 3 |1 3 2 |1 6 2 
|1 3 2 |4 1 1 |3 4 1 
|3 1 1 |3 1 1 |3 3 2 

____________________
|1 1 0 |0 0 0 |0 0 0 
|0 0 0 |0 0 0 |1 1 0 
|0 0 0 |0 0 1 |0 0 0 
____________________
|0 0 0 |1 1 0 |0 0 0 
|0 0 0 |0 0 0 |0 0 1 
|0 0 1 |0 0 0 |0 0 0 
____________________
|0 1 0 |0 1 0 |0 1 0 
|0 1 0 |1 0 0 |1 1 0 
|1 0 0 |1 0 0 |1 1 0 

____________________
|2 3 1 |1 1 2 |1 1 1 
|3 4 1 |3 1 1 |3 2 1 
|2 1 1 |3 2 1 |3 2 1 
____________________
|1 2 2 |2 3 1 |1 3 3 
|1 1 3 |2 1 3 |2 1 1 
|4 4 1 |1 2 3 |2 4 1 
____________________
|1 3 3 |1 3 2 |1 6 2 
|1 3 2 |4 1 1 |3 4 1 
|3 1 1 |3 1 1 |3 3 2