Mercurial > rlm
diff src/rlm/anti_battleship.clj @ 0:78a630e650d2
initial import
author | Robert McIntyre <rlm@mit.edu> |
---|---|
date | Tue, 18 Oct 2011 00:57:08 -0700 |
parents | |
children |
line wrap: on
line diff
1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/src/rlm/anti_battleship.clj Tue Oct 18 00:57:08 2011 -0700 1.3 @@ -0,0 +1,28 @@ 1.4 +(ns rlm.anti-battleship) 1.5 +(rlm.ns-rlm/ns-clone rlm.light-base) 1.6 + 1.7 + 1.8 + 1.9 + 1.10 + 1.11 +"need a board" 1.12 + 1.13 +"need some AI" 1.14 + 1.15 + 1.16 +"for now start off with two players on a rextangular geometry board 1.17 + (each discrete point on the board is a square)" 1.18 + 1.19 + 1.20 +"winning stragety should be to find a point that is known to contain the enemy's ship. 1.21 + then just hit every other point on the map ." 1.22 + 1.23 +"if it's always possible to find such a point, then whatever player goes second 1.24 + will always win." 1.25 + 1.26 +"can the finding of that point be tharwarted by ship layout?" 1.27 + 1.28 +"for certain types of boards/fleets --- YES" 1.29 + 1.30 +"most basic case is just with one ship that is a single point. then 1.31 + it's just blind luck, with the second player having a slight advantage"