Re: newbie question : about the perl sprintf

2009-10-24 Thread Peter Scott
On Wed, 21 Oct 2009 20:52:05 +0800, Majian wrote: And I modify it like this sprintf The number in scientific notation is %e, 01.255; The screen now output is The number in scientific notation is 1.255000e+03 Ha, this is an

Why Perl's representative is a camel?

2009-10-24 Thread netfox
I'm always wanting to know this. Thanks. -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: Why Perl's representative is a camel?

2009-10-24 Thread Erez Schatz
2009/10/24 net...@royal.net: I'm always wanting to know this. Thanks. O'Reilly media, publishers of Programming Perl (as well as Learning, Advance, Mastering, Best Practices, Cookbook and many other Perl books), have a practice of placing animal drawings on the cover of the books and the

Re: Why Perl's representative is a camel?

2009-10-24 Thread Shawn H Corey
Erez Schatz wrote: The Camel is actually a trademark of O'Reilly, and the Perl Foundation is using an onion logo, rather than a camel. There's also a saying among Perl programmers that Perl is like a camel, ugly but efficient. The merits of this saying is debatable. SHREK: strikeOgres

More on perl like tail

2009-10-24 Thread Harry Putnam
Sorry about being tricky with what was an older thread. But I suspect that thread died... and no one noticed there was an unaswered question still there. Shawn C originally suggested I use File::Tail. There was a short exchange about why and then I began trying to use File::Tail but haven't

printf and zero padding

2009-10-24 Thread Harry Putnam
With this little script, how would I manage to get the shorter timestamps zero padded using printf? I now how to get padded numbers but not when I'm pushing off the right margin too. cat script.pl #!/usr/local/bin/perl use strict; use warnings; while (my $file = shift @ARGV){ my

Re: printf and zero padding

2009-10-24 Thread Jim Gibson
At 4:02 PM -0500 10/24/09, Harry Putnam wrote: With this little script, how would I manage to get the shorter timestamps zero padded using printf? I now how to get padded numbers but not when I'm pushing off the right margin too. cat script.pl #!/usr/local/bin/perl use strict; use

Re: More on perl like tail

2009-10-24 Thread Jim Gibson
At 3:57 PM -0500 10/24/09, Harry Putnam wrote: Sorry about being tricky with what was an older thread. But I suspect that thread died... and no one noticed there was an unaswered question still there. Or no one knew the answer. Shawn C originally suggested I use File::Tail. There was a

Re: More on perl like tail

2009-10-24 Thread Harry Putnam
Jim Gibson jimsgib...@gmail.com writes: At 3:57 PM -0500 10/24/09, Harry Putnam wrote: Sorry about being tricky with what was an older thread. But I suspect that thread died... and no one noticed there was an unaswered question still there. Or no one knew the answer. He he... unlikely here I

About the $nextline question ~~

2009-10-24 Thread Majian
Hi,all: I have the text like this: xxx sum = 1, xx xx xx d_bits xxx xxx xx sum =0 xx xx xx d_bit xx My question is : How can I read the nextline after the d_bits if sum = 1? I thought it for some days, but had no result . Forgive I am maybe an newbie , please give me a hand ~~

Re: printf and zero padding

2009-10-24 Thread Harry Putnam
Jim Gibson jimsgib...@gmail.com writes: At 4:02 PM -0500 10/24/09, Harry Putnam wrote: With this little script, how would I manage to get the shorter timestamps zero padded using printf? I now how to get padded numbers but not when I'm pushing off the right margin too. cat script.pl

Re: About the $nextline question ~~

2009-10-24 Thread John W. Krahn
Majian wrote: Hi,all: I have the text like this: xxx sum = 1, xx xx xx d_bits xxx xxx xx sum =0 xx xx xx d_bit xx My question is : How can I read the nextline after the d_bits if sum = 1? $ echo xxx sum = 1, xx xx xx d_bits x1xx x2xx xx sum =0 xx xx xx d_bit xx | perl