Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

Re: Perl learns Blackjack

by seanbo (Chaplain)
on Jul 02, 2002 at 13:54 UTC ( [id://178850]=note: print w/replies, xml ) Need Help??


in reply to Perl learns Blackjack

my @DECK = qw(02 03 04 05 06 07 08 09 10 10 10 10 11);

What about if an ace is to be used as a 1? It can be either 1 or 11.


Update:DOH! I guess I should have read a little further. Thanks for the correction hossman.

perl -e 'print reverse qw/o b n a e s/;'

Replies are listed 'Best First'.
Re: Re: Perl learns Blackjack
by hossman (Prior) on Jul 02, 2002 at 18:13 UTC
    that's covered in his score method.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://178850]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others learning in the Monastery: (2)
As of 2024-04-26 00:31 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found