I found this in perlfunc:
@h = sort { $hashy{$b} <=> $hashy{$a} } keys %hashy;
Works perfectly :-)
Cheers
Evan Morris
[EMAIL PROTECTED]
Tel: +27 11 792 2777
Fax: +27 11 792 2711
- Original Message -
From: <[EMAIL PROTECTED]>
To: "Evan Morris" <[EMAIL PROTECTED]>
Cc: "$Bill Luebkert" <
Nasir Kamal writes:
> Split function in PERL.
> i want to split a sentence into words, i m using the following syntax:
>
> split(/ /,$line) note that I have given one space in between two slashes:
>
> however in $line sentence there are often more than one spaces, like 2 space
lee:
> >... The new ASP.NET allows you to separate the HTML from
> >the class files and C# and JScript.NET receive full object orientation
> >including virtuals, overrides, statics and abstracts. Throw in ADO.NET
> >and it's hard to beat.
>
> Throw my couple of thousand to buy it, and I may agree.
At 20:38 17/06/2002, Gerry Hickman wrote:
>... The new ASP.NET allows you to separate the HTML from
>the class files and C# and JScript.NET receive full object orientation
>including virtuals, overrides, statics and abstracts. Throw in ADO.NET
>and it's hard to beat.
Throw my couple of thousand
Nasir Kamal:
> Split function in PERL.
> i want to split a sentence into words, i m using the following syntax:
> split(/ /,$line) note that I have given one space in between two
slashes:
> however in $line sentence there are often more than one spaces, like 2
spaces or 3 spaces i
Use
the \s+ to match one or more whitespace characters, but includes more
than just the SPACE ascii value, the CR/LF characters, for
instance.
@words
= split( /\s+/, $line );
You
might want to look at the Text::ParseWords module, as is handles many
complex situations, like embedded quo
Evan Morris writes:
> Hi again
>
> I have successfully managed to read my csv file into a hash. I know have a
> hash containing value pairs of:
>
> product_id -- number_of_visits
>
> I know I can sort the hash by the keys, but is there any way to sort the
> hash by the values of the ke
Split function in PERL.
i want to split a sentence into words, i m using
the following syntax:
split(/ /,$line)
note that I have given one space in between two
slashes:
however in $line sentence there are often more than
one spaces, like 2 spaces or 3 spaces i want split
Hi again
I have successfully managed to read my csv file into a hash. I know have a
hash containing value pairs of:
product_id -- number_of_visits
I know I can sort the hash by the keys, but is there any way to sort the
hash by the values of the keys? Any recommendations?
Thanks in advance.
E
You can find free, small introductory audio tutorial to Perl along with slides at
http://www.peter.verhas.com/tutorials/
Audio is RealAudio, slides are ppt and HTML.
Regards,
Peter
___
ActivePerl mailing list
[EMAIL PROTECTED]
To unsubscribe: http://
From: Vitaly Sinitsin <[EMAIL PROTECTED]>
> why almost all Perl packages have: use Carp; ???
> Read help, but still not convinced...
Suppose you pass incorrect parameters to a function from a module.
What use will it be to you if you get an error on line XX inside the
module? You need to get th
From: "Robert Thorpe" <[EMAIL PROTECTED]>
> On 17 Jun 2002, at 22:10, Jenda Krynicky wrote:
>
> > > Defining interfaces - Not really much of a problem in my view.
> > > Again the document compares perl to CL which is certainly better
> > > in this regard, but this says more about how good CL is
Perl is the most powerful and far-reaching
computer language ever devised by the mind of man.
Period.
--
even the safest course is fraught with peril
___
ActivePerl mailing list
[EMAIL PROTECTED]
To unsubscribe: http://listserv.ActiveState.com/mail
> > > > Do you know any comments on this article from the Perl side?
> > > > http://www.garshol.priv.no/download/text/perl.html I'd appreciate
> > > > any URLs. I did a brief Google search and didn't find much.
I was going to keep my mouth shut, but I just read the article again...
I can't see h
Hi,
why almost all Perl packages have: use Carp; ???
Read help, but still not convinced...
Thank's.
___
ActivePerl mailing list
[EMAIL PROTECTED]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
Gerry Hickman :
> I think this has been true for a while with all the popular languages
> and platforms. When ASP came out JScript was not bad, but not really up
> to Perl standards. It was object based, but not quite object orientated,
> but what really made ASP was the ability to instantiate COM
16 matches
Mail list logo