The code for Skunk is found at http://www.dlugosz.com/Skunk1.zip.

I already found out something interesting, just from the brute-simple sample player that always rolls only once. 4 instances of the player will result in a wide spread of money changing hands, even though the number of individual game wins/losses is about 25% as you would expect.

Playing 10000 games. Sam (2536/7608) 1640 Judy (2528/7584) 931 Lloyd (2514/7542) 1134 Scott (2422/7266) -3705 [C:\work\dev\PerlSkunk]test2 test1 running loading sample1.skunk.pl Single Roller - Always rolls once. Playing 100000 games. Sam (25123/75369) 6037 Judy (24995/74985) -1504 Lloyd (24959/74877) -1948 Scott (24923/74769) -2585
The magnitude of the money spread grows with the total length of play, while the win/loss ratio should converge ever more accuratly to 25% as the length of plays increases.

This indicates that the money win/loss follows a fractal curve, with ever larger trends emerging the longer you play.

Ah, it's like a random walk! Which means I would expect the money to be +/- the square root of the number of games, further complicated by the fact that all the wins/losses must add up to zero.

So, I have documentation and a pretty good framework. I'd appreciate it if anyone reviewed the code to make sure there are no problems. And, anyone who wants to add a player robot is welcome to send it to me at 0binsnh002 "at" sneakemail.com (I'll change that once it gets on the spamlists).


In reply to The game of Skunk by John M. Dlugosz

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.