Beefy Boxes and Bandwidth Generously Provided by pair Networks
Come for the quick hacks, stay for the epiphanies.
 
PerlMonks  

comment on

( [id://3333]=superdoc: print w/replies, xml ) Need Help??
I ran the code for rack size 7. It took 12 hours 6 mins 18 secs on a 4 core Xeon box with 8 GB memory, OS linux. I am not going to copy the whole output here, just a few first and last lines:
MMVFWXQ => 6.24704795748769e-11 __BPMKQ => 6.24704795748769e-11 BCBMYHV => 6.24704795748769e-11 ... EEAIOND => 3.56231662727778e-05 EEAIONU => 3.56231662727778e-05 EEAIONL => 3.56231662727778e-05 Combinations: 8275164, Count: 16007560800.

I probably have an error in the code :-)

Update: I see it now. The error was my effort to "DRY". The @tiles array must be defined as follows to make it work:

my @tiles = (('_') x 2, # 2 blank tiles (scoring 0 points) # 1 point ('E') x 12, ('A') x 9, ('I') x 9, ('O') x 8, ('N') x 6, ('R') x 6, ('T') x 6, ('L') x 4, ('S') x 4, ('U') x 4, # 2 points ('D') x 4, ('G') x 3, # 3 points ('B') x 2, ('C') x 2, ('M') x 2, ('P') x 2, # 4 points ('F') x 2, ('H') x 2, ('V') x 2, ('W') x 2, ('Y') x 2, # 5 points ('K'), # 8 points qw(J X), # 10 points qw(Q Z));

Stay tuned, the next result is comming in 12 hours.

لսႽ† ᥲᥒ⚪⟊Ⴙᘓᖇ Ꮅᘓᖇ⎱ Ⴙᥲ𝇋ƙᘓᖇ

In reply to Re^3: Wordfeud racks by choroba
in thread Wordfeud racks by Anonymous Monk

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



  • Are you posting in the right place? Check out Where do I post X? to know for sure.
  • Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
    <code> <a> <b> <big> <blockquote> <br /> <dd> <dl> <dt> <em> <font> <h1> <h2> <h3> <h4> <h5> <h6> <hr /> <i> <li> <nbsp> <ol> <p> <small> <strike> <strong> <sub> <sup> <table> <td> <th> <tr> <tt> <u> <ul>
  • Snippets of code should be wrapped in <code> tags not <pre> tags. In fact, <pre> tags should generally be avoided. If they must be used, extreme care should be taken to ensure that their contents do not have long lines (<70 chars), in order to prevent horizontal scrolling (and possible janitor intervention).
  • Want more info? How to link or How to display code and escape characters are good places to start.
Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others romping around the Monastery: (6)
As of 2024-03-29 01:17 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found