WinBatch Tech Support Home

Database Search

If you can't find the information using the categories below, post a question over in our WinBatch Tech Support Forum.

TechHome

How to

Can't find the information you are looking for here? Then leave a message over on our WinBatch Tech Support Forum.

;Stones Cheat Script
;Bill P's how-to-win-at-stones script (Requires WinBatch)
;This script assumes you can take 1, 2, or 3 stones per turn
;(The standard game)
;Armed with this script, you too can win at stones maybe 75% of the time

ScriptTitle="Stones"
StonesLeft=2

MaxTakePerTurn=3
TheMagicNumber=MaxTakePerTurn+1

while StonesLeft>1
        StonesLeft="a"

        while isint(StonesLeft)==@false
                StonesLeft=strtrim(askline(ScriptTitle,"How many stones left?",""))

                if isint(StonesLeft)==@false then message(ScriptTitle,"Enter an integer, please, not '%StonesLeft%'.")
        endwhile

        if StonesLeft==1 then break

        MyMove=(StonesLeft-1) mod TheMagicNumber

        if MyMove==0 then MyMove=1 ; (More stones left to work with)

        if MyMove==1
                StoneWord="stone"
        else
                StoneWord="stones"
        endif

        message(ScriptTitle,"The best move is to take %MyMove% %StoneWord%.")
endwhile




Article ID:   W12478
Filename:   How to win at Stones.txt
File Created: 2017:07:28:13:58:11
Last Updated: 1999:04:15:16:47:30