Java Reference
In-Depth Information
int
[] play =
new i n t
[2];
play [0] = i ;
play [1] = decimalTab [ i ]
−
binaryToDecimal (binaryTab [ i ]) ;
return
play ;
}
public static void
main( String [ ]
args )
{
int
[ ]
game =
{
6, 9, 1, 2
}
;
do
{
int
tt = 0;
System . out . println () ;
for
(
int
i=0; i
<
game . length ; ++i )
{
System . out . print (game [ i ] +
""
);
t t += game [ i ] ;
System . out . println () ;
if
(tt
<
=0 )
break
;
System . out . p r i n t l n (Grundy(game) ) ;
int
[ ] play = pick (game) ;
System . out . println ( play [ 0 ] +
""
+play[1]);
game[play[0]]
−
=play[1];
}
while
(
true
);
}
}
Search WWH ::
Custom Search