On Nov 30, 2003, at 12:33 PM, B. Rothstein wrote:
If I have a scalar variable that itslef is a list of names and
numbers, for
example
$names = 'john 35, jack 18, albert 24, timmy 42'; is it possible, and
if
so how can it be done to separate the individual names and ages from
the
list in their
"B. Rothstein" wrote:
> If I have a scalar variable that itslef is a list of names and numbers, for
> example
> > $names = 'john 35, jack 18, albert 24, timmy 42'; is it possible, and if
> so how can it be done to separate the individual names and ages from the
> list in their scalar form in orde
If I have a scalar variable that itslef is a list of names and numbers, for
example
> $names = 'john 35, jack 18, albert 24, timmy 42'; is it possible, and if
so how can it be done to separate the individual names and ages from the
list in their scalar form in order to create new lists sorted by n
Keep your replies on the list and you won't have to wait for me to wake
up again for an answer. ;)
On Nov 30, 2003, at 4:33 AM, B. Rothstein wrote:
thanks for the functions, but for some reason the sort does not seem
to be
coming out correctly, any idea why?
By default, sort() works ASCIIbetic
On Nov 30, 2003, at 1:45 AM, B. Rothstein wrote:
If I have a scalar variable that itslef is a list of names, for example
$names = 'john, jack, albert, timmy"; is it possible, and if so how
can it
be done to separate the individual names from the list in their scalar
form
in order to create a new
Jeff Westman wrote:
> Hi Rob,
>
> --- Rob Dixon <[EMAIL PROTECTED]> wrote:
> > Jeff Westman wrote:
> > > --- George Schlossnagle <[EMAIL PROTECTED]> wrote:
> > > >
> > > > On Wednesday, June 4, 2003, at 02:40 PM, Wagner, David ---
> > > > Senior Programmer Analyst --- WGO wrote:
> > > >
> > > > >
Hi Rob,
--- Rob Dixon <[EMAIL PROTECTED]> wrote:
> Jeff Westman wrote:
> > --- George Schlossnagle <[EMAIL PROTECTED]> wrote:
> > >
> > > On Wednesday, June 4, 2003, at 02:40 PM, Wagner, David --- Senior
> > > Programmer Analyst --- WGO wrote:
> > >
> > > > Jeff Westman wrote:
> > > > > This may
Jeff Westman wrote:
> --- George Schlossnagle <[EMAIL PROTECTED]> wrote:
> >
> > On Wednesday, June 4, 2003, at 02:40 PM, Wagner, David --- Senior
> > Programmer Analyst --- WGO wrote:
> >
> > > Jeff Westman wrote:
> > > > This may sound trivial, but I am trying to declare and assign
> > > > multi
try
my ($a,$b)=("apples","apples");
In the other example it was pulling values from an array of scalars.
In your example you are only providing 1 scalar for 2 scalar variables to
share.
Royce
"The right word may be effective, but no word was ever as effective as a
rightly timed pause."
I like this solution! Cool
Thanks George and David.
JW
--- George Schlossnagle <[EMAIL PROTECTED]> wrote:
>
> On Wednesday, June 4, 2003, at 02:40 PM, Wagner, David --- Senior
> Programmer Analyst --- WGO wrote:
>
> > Jeff Westman wrote:
> >> This may sound trivial, but I am trying to
yeah, that works, but I was trying to do it in one statement as a scalar
assigment.
Thanks
JW
--- Stuart White <[EMAIL PROTECTED]> wrote:
> Would declaring all your variables with one my
> suffice? then your first line before use strict;
> should work. Like this:
>
> my ($a, $b);
> $a = $b =
Would declaring all your variables with one my
suffice? then your first line before use strict;
should work. Like this:
my ($a, $b);
$a = $b = 'apple';
--- Jeff Westman <[EMAIL PROTECTED]> wrote:
> This may sound trivial, but I am trying to declare
> and assign multiple
> scalars to the same v
On Wednesday, June 4, 2003, at 02:40 PM, Wagner, David --- Senior
Programmer Analyst --- WGO wrote:
Jeff Westman wrote:
This may sound trivial, but I am trying to declare and assign multiple
scalars to the same variable in the same statement. This is what I
have:
#!/bin/perl -w
$a = $b = "app
Jeff Westman wrote:
> This may sound trivial, but I am trying to declare and assign multiple
> scalars to the same variable in the same statement. This is what I
> have:
>
> #!/bin/perl -w
> $a = $b = "apple";# works
> use strict;
> my ($a = $b) = "apple"; # does not works
do:
my (
the seond char must be a letter and you can't have a . in a variable name
-Original Message-
From: Naveen Parmar [mailto:[EMAIL PROTECTED]]
Sent: Thursday, January 24, 2002 3:06 PM
To: [EMAIL PROTECTED]
Subject: Scalars
Why are the following 2 invalid scalar assignments?
B. $17april =
* Naveen Parmar ([EMAIL PROTECTED]) wrote:
> Why are the following 2 invalid scalar assignments?
>
> B. $17april = $dayDay 2;
> C. $april.17 = $dayDay 2;
>
> TIA,
> - NP
Looks like homework to me :)
--
___vvz __
(_, ` ) ( )Jeff Bisbee#!/usr/bin/perl -w
`~~~) )/\ [EMAIL
On Jan 24, Naveen Parmar said:
>Why are the following 2 invalid scalar assignments?
>
>B. $17april = $dayDay 2;
>C. $april.17 = $dayDay 2;
I'm not sure what it is you're trying to do here at all.
$17april is an invalid variable name, because:
a) if a variable name starts with digits, it must
17 matches
Mail list logo