On Mon, Mar 24, 2008 at 9:00 AM, <[EMAIL PROTECTED]> wrote:
> Hi ,
> Looking at the reg expression ( $playercard1 =~ /10|J|Q|K/ ),
> it will match 0, 1, and '10' , J, Q, K
>
> What must I do so that it will match only '10' , 'J', 'Q', and 'K'
>
> Thanks
/10|J|Q|K/ will not match 0 or 1 alone.
Hi ,
Looking at the reg expression ( $playercard1 =~ /10|J|Q|K/ ),
it will match 0, 1, and '10' , J, Q, K
What must I do so that it will match only '10' , 'J', 'Q', and 'K'
Thanks
- Original Message -
From: "Rodrick Brown" <[EMAIL PROTECTED]>
#!/usr/bin/perl -w
use strict;
use war
Thank You very much everyone here.
Thanks for providing me leads to study.
- Original Message -
"John W. Krahn" <[EMAIL PROTECTED]>,
Rodrick Brown wrote:
"Tom Phoenix" <
Gunnar Hjalmarsson
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
Rodrick Brown wrote:
On Tue, Mar 11, 2008 at 2:46 PM, Rodrick Brown <[EMAIL PROTECTED]> wrote:
On Tue, Mar 11, 2008 at 2:23 PM, <[EMAIL PROTECTED]> wrote:
How do I shorten this code:-
if $playercard1 = 10 or $playercard1 = "J" or $playercard1 = "Q" or
$player
On Tue, Mar 11, 2008 at 11:23 AM, <[EMAIL PROTECTED]> wrote:
> How do I shorten this code:-
>
> if $playercard1 = 10 or $playercard1 = "J" or $playercard1 = "Q" or
> $playercard1 = "K";
Here's my version of a program that does the same thi
On Tue, Mar 11, 2008 at 2:46 PM, Rodrick Brown <[EMAIL PROTECTED]> wrote:
>
> On Tue, Mar 11, 2008 at 2:23 PM, <[EMAIL PROTECTED]> wrote:
> > Hi,
> > How do I shorten this code:-
> >
> > if $playercard1 = 10 or $playercard1 = "J" or $playerc
[EMAIL PROTECTED] wrote:
How do I shorten this code:-
if $playercard1 = 10 or $playercard1 = "J" or $playercard1 = "Q" or
$playercard1 = "K";
That code does not compile. Besides that it would not do what you think
it would.
You probably want someth
On Tue, Mar 11, 2008 at 2:23 PM, <[EMAIL PROTECTED]> wrote:
> Hi,
> How do I shorten this code:-
>
> if $playercard1 = 10 or $playercard1 = "J" or $playercard1 = "Q" or
> $playercard1 = "K";
>
> Thanks
>
>
>
> --
> To
Hi,
How do I shorten this code:-
if $playercard1 = 10 or $playercard1 = "J" or $playercard1 = "Q" or
$playercard1 = "K";
Thanks
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/
On Sun, Mar 9, 2008 at 12:23 PM, <[EMAIL PROTECTED]> wrote:
> Hi,
> I wish to shuffle 8 decks of cards, so how do I shorten this code :-
>
> use Algorithm::Numerical::Shuffle qw /shuffle/;
> @eightdecks = shuffle
> (1..10,"J","Q","K",1..1
Hi,
I wish to shuffle 8 decks of cards, so how do I shorten this code :-
use Algorithm::Numerical::Shuffle qw /shuffle/;
@eightdecks = shuffle
(1..10,"J","Q","K",1..10,"J","Q","K",1..10,"J","Q","K");#how do I repeat 1 to K
32 times
print @eightdecks ;
11 matches
Mail list logo