Hash Performance/Optimization

2002-02-07 Thread Gfoo
Hello, I' m using a hash with quite long strings (scalars) used for its keys and values. I'm wondering how the size of these strings used (for keys and values) and the number of elements in the hash affect the hash performance and memory consumption. Are there any suggestions about hashes rega

remove part of a string - unterminated tags

2002-03-25 Thread Gfoo
Hello all... I have strings like the following one: my $s="The Library of Library of ..." (that is remove 'unterminated' html tags - tags that open but there is no '>' at the end, and add "..." if necessary) By using the following: $s=~s/<(?!.*?>)//; I only get a removal of the non-matching '<'

RE: remove part of a string - unterminated tags

2002-03-25 Thread Gfoo
[EMAIL PROTECTED] (David Gray) wrote in 003401c1d41a$595140e0$[EMAIL PROTECTED]:">news:003401c1d41a$595140e0$[EMAIL PROTECTED]: >> I have strings like the following one: >> my $s="The Library of > >> I want to truncate the string, to become >> "The Library of ..." >> (that is remove 'unterminat

RE: remove part of a string - unterminated tags

2002-03-26 Thread Gfoo
[EMAIL PROTECTED] (David Gray) wrote in 01c1d435$f2306e60$[EMAIL PROTECTED]:">news:01c1d435$f2306e60$[EMAIL PROTECTED]: >> >> I have strings like the following one: >> >> my $s="The Library of > >> >> >> I want to truncate the string, to become >> >> "The Library of ..." >> >> (that is

Closures / Memory Usage

2002-08-31 Thread Gfoo
of $food keys/values inside each function instead of putting them all on top of the file? Another related question: I have these subs inside a module. Assume that I use the first way (#1). Since I 'use' this module in an other perl file, will all the $food hash stay in memory as long as the other perl file is running? Thank you, GFoo -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]