Tielman Koekemoer (TNE) wrote:
Thanks all for your info - VERY informative. Although I now feel the
need to say: Hang in there Charles. I'm sure not all Perl babes rate
their partners according to their scripting prowess.
All drop-dead gorgeous Perl programmers, you know who to contact...
;)
Hi All,
I'm trying to find a way to compare the files and folders contained within 2
separate directory structures to determine whether they are identical or not.
For this I tried using the File::Find module but got stuck at a certain point.
I looked online and in some books but couldnt find a
Hi,
I am running perl-5.8.6 on z/OS. How do I debug XS code ?
1) I have a specific function static SV *encode_method() in a xs file. The
fn name remains the same in the corresponding c file. I am unable to break
at this fn within the c file although perl is built with -g. Any thoughts on
how to
Am Dienstag, 10. Mai 2005 08.34 schrieb [EMAIL PROTECTED]:
Hi All,
I'm trying to find a way to compare the files and folders contained within
2 separate directory structures to determine whether they are identical or
not. For this I tried using the File::Find module but got stuck at a
Ok, thank you much.
Teddy
- Original Message -
From: Chris Charley [EMAIL PROTECTED]
To: beginners@perl.org
Sent: Monday, May 09, 2005 11:07 PM
Subject: Re: sorting a hash
Hi Teddy
This works :-)
for (sort byname keys %$ref) {
print $_ has the name $ref-{$_}{name} and has
Or you can try:
__BEGIN__
#!/usr/bin/perl
use warnings;
use strict;
my @decimals;
$_ = 'atom 12 N VAL A 1 12.435 13.66 34.6 32.1 32 a N';
push @decimals,$1 while (/(\d+\.?\d*)/g);
print @decimals\n;
__END__
On Mon, 9 May 2005 19:04:08 +0530
Aditi Gupta [EMAIL PROTECTED] wrote:
Hi
Am Dienstag, 10. Mai 2005 09.14 schrieb FreeFall:
use warnings;
use strict;
my @decimals;
$_ = 'atom 12 N VAL A 1 12.435 13.66 34.6 32.1 32 a N';
push @decimals,$1 while (/(\d+\.?\d*)/g);
print @decimals\n;
Or, shorter (no need to use while _and_ //g):
use warnings;
use strict;
On Tue, 10 May 2005 09:22:31 +0200
John Doe [EMAIL PROTECTED] wrote:
my @decimals= /(\d+\.?\d*)/g;
cool! Thanks!
--
Whatever you do will be insignificant,but
the important is you do it!
It doesn't matter who you are, it's what
you do that takes you far!
--
To unsubscribe, e-mail: [EMAIL
John Doe [JD], on Tuesday, May 10, 2005 at 09:22 (+0200) made these
points:
JD Or, shorter (no need to use while _and_ //g):
JD use warnings;
JD use strict;
JD $_ = 'atom 12 N VAL A 1 12.435 13.66 34.6 32.1 32 a N';
JD my @decimals= /(\d+\.?\d*)/g;
JD print @decimals\n;
very nice
Dear Sirs,
I could not able to store data into single array variable by using
@sampletext=qw/
/;
But the data has /,\,:,;{,},[,],%,$,#,@, ... everything in keyboard
characters.
suppose the data contains / then it says some error
Search pattern not terminated at style.pl line 24.
Kindly
I need to compute the total elapsed time with this
format:
start end Total
06:30:17 09:00:14 2.50 hours
Do you know any shortcut to this instead of splitting
each number in between colons?
Discover Yahoo!
Get on-the-go sports scores, stock quotes, news
baskaran [b], on Tuesday, May 10, 2005 at 13:13 (+0530) contributed
this to our collective wisdom:
b suppose the data contains / then it says some error
b Search pattern not terminated at style.pl line 24.
b Kindly suggest me a solution.
try to escape that with \; so you have \/.
should work.
Harold Castro [HC], on Tuesday, May 10, 2005 at 00:54 (-0700 (PDT))
wrote these comments:
HC start end Total
HC 06:30:17 09:00:14 2.50 hours
HC Do you know any shortcut to this instead of splitting
HC each number in between colons?
never need this, but you should look at:
Is there any good reference/web-site from which I can get a better
understanding of thread::shared module.
I see this error when I execute my file.
error: thread failed to start: Invalid value for shared scalar
When does this error occur?
Thanks
Anbu Gandhi
Hi all,
I have tried various regular expressions to remove null or empty
values on array @array1 and create a new array @OPD01 with the values.
This, however, does not work as I still get a number of empty values
in the @OPD01 array after this processing. As you'll see I tried
various things -
Am Dienstag, 10. Mai 2005 11.01 schrieb Tielman Koekemoer (TNE):
Hi all,
I have tried various regular expressions to remove null or empty
values on array @array1 and create a new array @OPD01 with the values.
This, however, does not work as I still get a number of empty values
in the @OPD01
Tielman Koekemoer (TNE) [TK], on Tuesday, May 10, 2005 at 11:01
(+0200) contributed this to our collective wisdom:
TK I have tried various regular expressions to remove null or empty
TK values on array @array1 and create a new array @OPD01 with the values.
TK This, however, does not work as I
Hi John,
Try to use 'chop' to get null value
Thanks and Regards
Pramod
John Doe wrote:
Am Dienstag, 10. Mai 2005 11.01 schrieb Tielman Koekemoer (TNE):
Hi all,
I have tried various regular expressions to remove null or empty
values on array @array1 and create a new array @OPD01 with the values.
$counter2 = 0;
What's that for? (never used)
Hmm yeah sorry that was supposed to be $counter = 0;
Use push() to avoid holding the current array index.
What do you mean by holding the index?
my @array1=(' ', 'a', '', 'b', \0, 'c', undef, 'd', ' ', 'e'); my
@new=grep {$_ and !/^\s+$/ and
Sincerely your,
sanobabu
[EMAIL PROTECTED]
-- www.MailNavigator.com - Find your email and news!
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/ http://learn.perl.org/first-response
Ah I see: use push() to add scalars/lists to arrays.
Thanks everyone for the help.
Use push() to avoid holding the current array index.
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/ http://learn.perl.org/first-response
John == John Doe [EMAIL PROTECTED] writes:
John Something like (untested):
John # build hashes with pairs (filename=0)
John #
John my %first=map {$_=1} find (sub {}, $dir1);
John my %second=map {$_=1} find (sub {}, $dir2);
Good thing that untested is in there, because find() doesn't return
Hi,
I have a Perl script that requires the following module to be installed.
use File::Find;
open(IN,$File::Find::name) or ...
WHen I ran the PPM and did a search for Find I couldn't find the module
File-Find? Which one do I have to install?
This is what gets listed:
26.
Hi Flash -:)
Usually the File::Find module is already installed with your perl
distribution.
CO
-Original Message-
From: FlashMX [mailto:[EMAIL PROTECTED]
Sent: 10 mai 2005 15:42
To: beginners@perl.org
Subject: Re: Setup of ActivePerl Modules HELP!
Hi,
I have a Perl script that
- Original Message -
From: Chris Charley [EMAIL PROTECTED]
To: beginners@perl.org
Sent: Monday, May 09, 2005 7:03 PM
Subject: Re: sorting a hash
- Original Message -
From: [EMAIL PROTECTED]
Newsgroups: perl.beginners
To: Octavian Rasnita [EMAIL PROTECTED]; beginners@perl.org
As I know, Becky! Ver.2 with a plugin can download all newsgroup messages as if
they are
regular mails.(Very huge messages stacked in your disk!)
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/
Can someone help me out with this simple code? It gives an error saying:
Illegal division by zero at test.pl line 4.
Exit 255
Code:
-
#!/usr/local/bin/perl
sub test {
=09my @[EMAIL PROTECTED];
=09my $div=3D$pars[0]/$par[1];
=09print Pars were @{_}\n;
}
Hi,
I have a Perl script that requires the following module to be installed.
use File::Find;
open(IN,$File::Find::name) or ...
type something like that. btw, it's in the documentation :-)
perl -MFile::Find -e 1;# if it doesn't complain it's installed
--manfred
--
To unsubscribe, e-mail:
-Original Message-
From: Madhur Kashyap [mailto:[EMAIL PROTECTED]
Sent: Tuesday, May 10, 2005 11:34 AM
To: beginners@perl.org
Subject: Urgent Help with functions
Can someone help me out with this simple code? It gives an
error saying:
Illegal division by zero at test.pl
On 5/10/05, Larsen, Errin M HMMA/IT [EMAIL PROTECTED] wrote:
-Original Message-
From: Madhur Kashyap [mailto:[EMAIL PROTECTED]
Sent: Tuesday, May 10, 2005 11:34 AM
To: beginners@perl.org
Subject: Urgent Help with functions
Can someone help me out with this simple code? It
Am Dienstag, 10. Mai 2005 13.54 schrieb Randal L. Schwartz:
John == John Doe [EMAIL PROTECTED] writes:
John Something like (untested):
John # build hashes with pairs (filename=0)
John #
John my %first=map {$_=1} find (sub {}, $dir1);
John my %second=map {$_=1} find (sub {}, $dir2);
Good
Am Dienstag, 10. Mai 2005 11.46 schrieb Tielman Koekemoer (TNE):
$counter2 = 0;
What's that for? (never used)
Hmm yeah sorry that was supposed to be $counter = 0;
Use push() to avoid holding the current array index.
What do you mean by holding the index?
remember (and incrementing) the
Am Dienstag, 10. Mai 2005 11.23 schrieb Kpramod:
Hi John,
Try to use 'chop' to get null value
Thanks and Regards
Pramod
Hi Pramad,
sorry, I don't understand what you mean. Do you refer to the line
my @new=grep {$_ and !/^\s+$/ and !/^\0+$/} @array1;
(I see that the test for \0 is ugly,
Hi Graeme
Based on the code snippets you provide, it's not clear (at least to me) what
you want to achieve. Is it possible that you post the module?
Am Dienstag, 10. Mai 2005 13.34 schrieb Graeme McLaren:
John, here's the function I'm talking about.
an object method?
I want to return a
baskaran wrote:
Dear Sirs,
Hello,
I could not able to store data into single array variable by using
@sampletext=qw/
/;
But the data has /,\,:,;{,},[,],%,$,#,@, ... everything in keyboard
characters.
suppose the data contains / then it says some error
Search pattern not terminated at style.pl line
On Tue, May 10, 2005 at 10:03:57PM +0530, Madhur Kashyap wrote:
Can someone help me out with this simple code? It gives an error saying:
Illegal division by zero at test.pl line 4.
Exit 255
Code:
-
#!/usr/local/bin/perl
sub test {
=09my
-Original Message-
From: Madhur Kashyap [mailto:[EMAIL PROTECTED]
Sent: Tuesday, May 10, 2005 12:34 PM
To: beginners@perl.org
Subject: Urgent Help with functions
Can someone help me out with this simple code? It gives an error saying:
Illegal division by zero at test.pl line 4.
Exit
Hi
I have a string which reoccuring patterns
1abc2abc3abc4abc567
How do I remove everything before the 1st occrence of abc to get the
result
2abc3abc4abc567
s/^.*abc//
Gives me
567
Thanks in advance.
Philip
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail:
HI all, I have a function which is tying a hash and when I pass it to
another function I want to be able to get the values of the hash in the
order they were set in, how would I do this?
Here's the function with the hash:
sub
Grant wrote:
Hello, I'm trying to make a successful request to the Google AdWords
API. My Perl skills are extremelly weak. Here's the error I'm
getting:
SOAP Fault: org.xml.sax.SAXException: SimpleDeserializer encountered a
child element, which is NOT expected, in something it was trying
To: 'Tham, Philip'
Subject: RE: Help with substitution
Subject: Help with substitution
Hi
I have a string which reoccuring patterns
1abc2abc3abc4abc567
How do I remove everything before the 1st occrence of abc to get the
result
2abc3abc4abc567
s/^.*abc//
Gives me
567
Thanks in advance.
This worked for me. Don't forget the 'greedy' regex:
s/^.*?(abc)//;
-Original Message-
From: Tham, Philip [mailto:[EMAIL PROTECTED]
Sent: Tuesday, May 10, 2005 3:59 PM
To: beginners@perl.org
Subject: Help with substitution
Hi
I have a string which reoccuring patterns
I'm kind of lost as to what you're actually trying to do. Instead of
posting functions with nothing calling them, you should include a code
snippet (as simple as possible) that can be run to demonstrate the
problem. Preferably not using those functions. Fix one thing at a
time.
With that said,
-Original Message-
From: Larsen, Errin M HMMA/IT [mailto:[EMAIL PROTECTED]
Sent: Friday, May 06, 2005 8:15 AM
To: beginners@perl.org
Subject: gcc on Solaris
...
And I execute the following command line to test the gcc installation:
# gcc helloworld.c -o helloworld
ld.so.1: gcc:
Thanks for the help
Lessons learned as a beginner:
1) Never write codes when you are sleepy.
2) Always use strict/warnings pragma, that will be extremely helpful
incase you can't obey previous rule.
Hope thats important for every beginner.
On 5/11/05, Paul Johnson [EMAIL PROTECTED] wrote:
N. Ganesh Babu wrote:
Dear All,
My requirement is to compare the typing exam results.
For Example:
1. 281 and 289 are the text files of the candidates.
2. I am having master.txt
3. I need to compare the 281 with master.txt and get the result.
4. I need to compare the 289 with master.txt and get
46 matches
Mail list logo