Re: stupid question about to protect source code of perl web application scripting

2019-07-09 Thread Kent Fredric
On Mon, 8 Jul 2019 at 13:45, Eko Budiharto wrote: > > dear all, > > first of all, thank you for the respond of my inquiry. And then, there > is a few questions I would like to ask: > > 1. if someone takes your works and then he steals the credit by claiming > the work is his work instead of your

Re: stupid question about to protect source code of perl web application scripting

2019-07-07 Thread Kent Fredric
> On 7/6/19 11:21 PM, Eko Budiharto wrote: > > it is a web application but it is on premise. The user is not honest. > > That's why I am trying to find a way to protect the source code like > > in java we can compile into java class and still can be run. That's a false sense of securtiy. A

Re: confidence under BEGIN{}

2018-07-26 Thread Kent Fredric
On 27 July 2018 at 05:21, Andy Bach wrote: > > or, as Perl treats the "::" as a path denoter: > $ perl -e 'use test::mytest; mytest::hello()' > hello > > or: > $ perl -mtest::mytest -e 'mytest::hello()' > hello > > find ./test/mytest.pm via @INC's "." Note: neither of those examples work on

Re: Heredocs with \r\n on linux

2017-10-15 Thread Kent Fredric
On 16 October 2017 at 12:21, Rui Fernandes wrote: > Hi > > Did you try to declare before all the code (right after the modules): > > print "Content-type: text/html\n\n"; > > ? > > Cheers > > I don't understand why this reply is here, or what you expect it does. That

Re: Heredocs with \r\n on linux

2017-10-15 Thread Kent Fredric
On 16 October 2017 at 11:24, David Santiago wrote: > > Hi. > > How can i have \r\n on my heredoc string when i run my script in linux? > > my $text=<<"END"; > This is one line > This is another one > Final line > END > > When i print this var in my linux box, i get this: >

Re: Fwd: Re: dangerous perl (Re: is this reasonably save?)

2017-05-26 Thread Kent Fredric
On 27 May 2017 at 00:01, lee wrote: > You have a variable. Even in C, you'd have a variable as well. It would be a variable that contains a *pointer* to a data structure. The variable may be *typed*, but *types* don't impact anything about the data storage in memory. *types*

Re: Fwd: Re: dangerous perl (Re: is this reasonably save?)

2017-05-25 Thread Kent Fredric
On 26 May 2017 at 05:33, lee wrote: > Perl doesn't have data structures, so variables in perl are not data > structures. That is unfortunate. So when I write: my $var = { memory => { total => 1024, free => 100, buffers => 10,

Re: Regex for matching files that don't have type extensions

2016-11-05 Thread Kent Fredric
On 6 November 2016 at 06:14, Jovan Trujillo wrote: > > 1207003PE_GM_09TNPLM2.csv > > I originally though m/[A-Za-z0-9\_]+/ would work, but it captures both > strings. > So then I tried m/[A-Za-z0-9\_]+(?!\.)/ but I still get both strings > captured. Alternatively, if

Re: if element exists in an array

2016-08-18 Thread Kent Fredric
On 19 August 2016 at 13:45, Kent Fredric <kentfred...@gmail.com> wrote: >if ( first { $item == 4 } @items ) { >say "Yes"; >} > Ugh, my bad. if ( first { $_ == 4 } @items ) { say "Yes"; } -- Kent KENTNL - https://metacpan

Re: if element exists in an array

2016-08-18 Thread Kent Fredric
On 19 August 2016 at 13:35, wrote: > > What's the better way to decide if an element exists in an array? > Something like what ruby does, > > irb(main):001:0> x=[3,1,4,2,9,0] > => [3, 1, 4, 2, 9, 0] > irb(main):002:0> x.include? 4 > => true > irb(main):003:0> x.include? 10 >

Re: Script runs slower with better hardware

2016-06-01 Thread Kent Fredric
On 2 June 2016 at 08:04, David Emanuel da Costa Santiago wrote: > They are using the same verion of Net::SSLeay (version 1.72). All the > software have the same version. No, not Net::SSLeay ... OpenSSL, which it links against. And if you recently upgraded/downgraded OpenSSL

Re: Script runs slower with better hardware

2016-06-01 Thread Kent Fredric
On 2 June 2016 at 06:25, David Emanuel da Costa Santiago wrote: > The question for one million dollar is "Why?". And how can i improve > the performance of my desktop to reach the same speed as my laptop > (considering that i have better hardware on my desktop)? If i recompile

Re: Are there (non-obvious) differences in string quoting methods?

2016-04-06 Thread Kent Fredric
On 7 April 2016 at 07:20, Jonathon Fernyhough wrote: > > qq{} obviously wins when there would otherwise be a lot of escaping, but > are there any downsides of using this method more generally (other than > double-quotes being two characters shorter)? For example, is it

Re: reading directories using perl in windows

2016-03-01 Thread Kent Fredric
On 1 March 2016 at 23:23, Arghya Das wrote: > $dir = "c:/folder/*"; > my @files = glob( $dir ); > > foreach (@files ){ >print $_ . "\n"; > } Personally, I would have used either Path::Tiny, or at least, readdir() here. There's far few places that can lead to strange

Re: coding help

2016-02-29 Thread Kent Fredric
On 1 March 2016 at 19:35, Arghya Das wrote: > $num = 1234; > $sum = 0; > > while ( $num != 0) > { > $rem = $num % 10; > $sum = ( $sum * 10 ) + $rem; > $num = $num / 10; > } > > print $sum; I suspect you're just exceeding precision limits. Modified code: use strict; use

Re: use of bless

2016-02-28 Thread Kent Fredric
On 28 February 2016 at 21:59, rakesh sharma wrote: > According to docs bless returns the reference to self. That just means that if you do: my $x = {}; my $y = bless $x, "THING"; $y and $x will both be the same thing, a {} blessed into "Thing" Its just more

Re: Counter Help

2016-02-12 Thread Kent Fredric
On 10 February 2016 at 03:46, James Kerwin wrote: > (I'm a bit wary of hashes because they're weird). If you want a nice way to reason about hashes when you're really new, there's something that you probably already understand you can borrow understanding from: Folders.

Re: Counter Help

2016-02-12 Thread Kent Fredric
On 13 February 2016 at 07:39, timothy adigun <2teezp...@gmail.com> wrote: > And hashes keys/values can't be sorted? Just saying.. :) In my other message where I give an analogy to a "Folder" or "Directory" in a file system. Can you sort a folder? ... not really. They don't really have an

Re: Counter Help

2016-02-12 Thread Kent Fredric
On 13 February 2016 at 08:38, timothy adigun <2teezp...@gmail.com> wrote: > In your analogy, if hashes are like folder, keys and values are like what? > Name of folders. If yes, can those be sorted? If yes, they you have just > made my point.. :) Keys are files. Values are file contents.

Re: Counter Help

2016-02-12 Thread Kent Fredric
On 13 February 2016 at 10:08, Kent Fredric <kentfred...@gmail.com> wrote: > > All you're doing is sorting the *view* of it. Not the data itself. If you want a demonstration of this fact, on a Linux filesystem, poke around with 'find'. Or if you've got Path::Iterator::Rule installed:

Re: returning arrays

2016-01-25 Thread Kent Fredric
On 26 January 2016 at 12:02, Nathan Hilterbrand wrote: > return wantarray() ? ($a, $b) : [$a, $b]; > > In a list context, you get back a list.. otherwise you get back a reference > to a list. Might not be what you want, though. > > Works with arrays, too.. > > my @anarray =

Re: Is perl user specific

2016-01-07 Thread Kent Fredric
On 7 January 2016 at 04:34, Ankita Rath wrote: > Perl 5.008003 required--this is only version 5.00503, stopped at > ../Modules/Modules_64/5.8.5/x86_64-linux-thread-multi/YAML/XS.pm line 26. > BEGIN failed--compilation aborted at >

Re: Perl 6

2015-12-15 Thread Kent Fredric
On 15 December 2015 at 21:59, Jitendra Barik wrote: > Please let me know difference between Perl 5 and Perl 6? They are different languages. At least, they are as different as Ruby and Perl 5, if not more so. After all, there's not a lot of programming languages with

Re: XML Simple + parsing inner loop elements + help

2015-12-08 Thread Kent Fredric
On 8 December 2015 at 19:25, perl kamal wrote: > I am trying to parse the inner loop elements of the attached input xml > elements. > The below code doesn't retrieve the inner loop() elements if > the properties tag contains more than one item. Will you please point > the

Re: passwords in Perl

2015-10-27 Thread Kent Fredric
On 27 October 2015 at 20:25, shawn wilson wrote: > do to manage policies and prevent users from using weak passwords and > emulate them. And if you want some examples on how *NOT* to restrict passwords, this site catalogues a lot of embarrasing failures.

Re: passwords in Perl

2015-10-27 Thread Kent Fredric
On 28 October 2015 at 06:26, shawn wilson wrote: > time*tries*exp is probably more like what you want, and do it before > you print the error, but yeah Just make sure the backoff can't be exploited by malicious users to lock out legitimate users by bombing the login system

Re: File::Sluprer (Re: Multi line file handling)

2015-10-19 Thread Kent Fredric
On 20 October 2015 at 03:55, Lars Noodén wrote: > What is the main reason for the preference of File::Slurper over > File::Slurp these days? http://blogs.perl.org/users/leon_timmermans/2015/08/fileslurp-is-broken-and-wrong.html -- Kent KENTNL -

Re: Best way to indicate module author tests?

2015-08-05 Thread Kent Fredric
On 6 August 2015 at 09:24, Alex Becker asb.c...@gmail.com wrote: I started to use Test::POD and Test__POD::Coverage in my modules. However, I got the feedback that these tests should not be done when someone installs the module from CPAN. The logic is quite clear: POD issues are not critical.

Re: To use signatures or not to use?

2015-07-22 Thread Kent Fredric
On 23 July 2015 at 07:11, Alex Becker asb.c...@gmail.com wrote: Perl now has subroutine signatures. However, they are marked as experimental feature. As I really like it, I'm always tempted to use it. On the other hand, I don't want to wast efforts to something I have to roll back. So,

Re: Regexp under PERL

2015-07-08 Thread Kent Fredric
On 8 July 2015 at 19:12, Nagy Tamas (TVI-GmbH) tamas.n...@tvi-gmbh.de wrote: This is the code: } elsif (defined($row) ($row =~ m/\(\*[ ]+\\@PATH\[ ]+:=[ ]+'(\/)?([\*A-Za-z_ ]*(\/)?)+'[ ]\*\)?/)) { # PATH first version: \(\*[ ]+@PATH[ ]+:=[ ]+'(\\/)?([\*A-Za-z_ ]*(\\/)?)+'[ ]\*\)?

Re: using hash_value from Hash::Util

2015-07-08 Thread Kent Fredric
On 8 July 2015 at 21:51, Nagy Tamas (TVI-GmbH) tamas.n...@tvi-gmbh.de wrote: hash_value is not exported by the Hash::Util module bucket_stats is not exported by the Hash::Util module bucket_info is not exported by the Hash::Util module bucket_array is not exported by the Hash::Util module

Re: using hash_value from Hash::Util

2015-07-08 Thread Kent Fredric
On 8 July 2015 at 23:19, Nagy Tamas (TVI-GmbH) tamas.n...@tvi-gmbh.de wrote: Is it a documentation mistake? Do you have perl 5.22? perl -MHash::Util=hash_value -E1 # Fine. There is no mistake. Those functions started being present in perl 5.18. If you don't have them, you either have an

Re: using hash_value from Hash::Util

2015-07-08 Thread Kent Fredric
On 8 July 2015 at 23:00, Kent Fredric kentfred...@gmail.com wrote: impervious to accidentally typing trailing spaces inside the quotes: Ugh. I forgot to note: you can read on these operators in : perldoc -f qw perldoc perlop # search for Quote-Like -- Kent KENTNL - https://metacpan.org

Re: Regexp under PERL

2015-07-07 Thread Kent Fredric
On 8 July 2015 at 04:40, Nagy Tamas (TVI-GmbH) tamas.n...@tvi-gmbh.de wrote: m/\(\*[ ]+\\@PATH\[ ]+:=[ ]+'(\/)?([\*A-Za-z_ ]*(\/)?)+'[ ]\*\)?/)) This is not the exact code you 're using obviously, because the last 2 ) marks are actually outside the regex. Removing those ))'s makes the regex

Re: Use of uninitialized value $j in numeric eq (==) at myfile line 125

2015-07-06 Thread Kent Fredric
On 6 July 2015 at 19:15, Nagy Tamas (TVI-GmbH) tamas.n...@tvi-gmbh.de wrote: use XML::writer; Is that supposed to be XML::Writer , or is it really XML::writer? Either way, its irrelevant because its not used anywhere. Can you produce an XML file that will repeat the problem, the attached

Re: Use of uninitialized value $j in numeric eq (==) at myfile line 125

2015-07-06 Thread Kent Fredric
On 6 July 2015 at 19:43, Nagy Tamas (TVI-GmbH) tamas.n...@tvi-gmbh.de wrote: Yes, I can produce an XML file. I mean, can you paste-bin or attach an XML file which is minimal in size, yet, still causes this problem to occur, so that we may also attempt to see what is happening using said file.

Re: Threads in Perl

2015-07-06 Thread Kent Fredric
On 7 July 2015 at 15:57, Akshay Mohit akshaymohit2...@gmail.com wrote: I am not so experienced in Perl and got a task to do in Threads. The first question you have to ask is Why do you need threads. What are you doing? Many people go I need some sort of parallel process and go that needs

Re: Threads in Perl

2015-07-06 Thread Kent Fredric
On 7 July 2015 at 16:14, Akshay Mohit akshaymohit2...@gmail.com wrote: I need to maintain a code for performance testing which is fully written using Threads That doesn't seem to help me a lot. Because Performance testing in itself doesn't require threads. If you just need to load up

Re: Threads in Perl

2015-07-06 Thread Kent Fredric
On 7 July 2015 at 16:41, Akshay Mohit akshaymohit2...@gmail.com wrote: As I told earlier there is a code already written on Performance testing using Perl threads and I need to maintain and own it because the person who was doing it earlier left the organization, so I am bound to maintain the

Re: Perl Hash concept.

2015-07-03 Thread Kent Fredric
On 3 July 2015 at 18:54, bikram behera jobforbik...@gmail.com wrote: Hi Team, Any body can explain me how to do perl hash refernce and dereference. Create a hash: my (%hash) = ( key = value , otherkey = othervalue ); Create a reference to said hash: my $reference = \%hash; You can also

Re: Customized Module Concept

2015-07-03 Thread Kent Fredric
On 3 July 2015 at 19:18, ayush kabra ayush.kab...@gmail.com wrote: I want to make customized module on perl but i don't know how to make it. i have checked on google but it's little bit confusing. i am not able to understand what is the meaning of EXPORTER_OK ,IMPORT and there is lot of thinh

Re: How to check the index positions of an array element in perl in case of multiple occurance

2015-06-16 Thread Kent Fredric
On 17 June 2015 at 04:46, Vincent Lequertier s...@riseup.net wrote: #!/usr/bin/perl use strict; use warnings; open my $fh, '', 'text'; my @words = split ' ', $fh; my @matchs; while (my ($index, $elem) = each @words) { if ($elem eq 'bspwrt') { push @matchs, $index++;

Re: Need help

2015-04-08 Thread Kent Fredric
On 9 April 2015 at 05:40, ayush kabra ayush.kab...@gmail.com wrote: I need little bit help. i need to sort a file according to its 3rd column and i need the output. can you please help me on this. Input file we can take anyone either .txt or .xls or .csv. Please look into this and help me.

Re: catching utf8 errors

2015-03-15 Thread Kent Fredric
On 15 March 2015 at 20:07, Manfred Lotz manfred.l...@arcor.de wrote: I prefer the method Charles showed. But nevertheless your method is interesting as well. FWIW, SIG{__WARN__} is much preferred over redirecting stderr to simply suppress/capture/filter warnings. For instance, if somebody

Re: catching utf8 errors

2015-03-15 Thread Kent Fredric
On 15 March 2015 at 21:41, Manfred Lotz manfred.l...@arcor.de wrote: I agree but I thought that in this case I would need to know the potential warning messages the :encoding(UTF-8) could issue in order to take action in those particular cases. Using a section local { open( local

Re: catching utf8 errors

2015-03-14 Thread Kent Fredric
On 14 March 2015 at 22:38, Manfred Lotz manfred.l...@arcor.de wrote: following error message which is fine. Sorry for being pedantic, but I think you'll find that those are what we call warnings, not errors. Errors tend to be fatal. However, curiously, :utf8 's warnings seems to be regulated

Re: Need something like macro

2015-03-09 Thread Kent Fredric
On 10 March 2015 at 00:56, Артём Варнайский varnays...@mail.ru wrote: I used a nytprof to check performance, function call reduces it. Its not just reduces it that matters. Its whether reducing it in the grand scale of things is really important. ( vs other parts of the system / general

Re: Re[2]: Need something like macro

2015-03-09 Thread Kent Fredric
On 10 March 2015 at 09:01, John SJ Anderson geneh...@genehack.org wrote: And the average latency of the network connection you're serving this captcha over is... ? Its probably a bigger issue if you have 2,000 customers at any time fetching captchas =). But the question is more Not is the

Re: Need something like macro

2015-03-08 Thread Kent Fredric
On 9 March 2015 at 03:11, Артём Варнайский varnays...@mail.ru wrote: due to performance issues Important question: How did you prove this was a performance issue. Because unless you've a) profiled your code b) benchmarked your code c) seen that the performance is significantly impeded by

Re: Use vs Require with version number

2015-03-05 Thread Kent Fredric
On 5 March 2015 at 17:15, Brandon McCaig bamcc...@gmail.com wrote: Uri means that use is effectively requiring the module with a BEGIN block. That means that it will execute before any other code that isn't in a BEGIN block. It may also be worth mentioning that BEGIN is actually a sub. A

Re: $CONFIG_FILE

2015-02-20 Thread Kent Fredric
On 21 February 2015 at 01:38, nicolas nicolas...@mail.com wrote: Global symbol $CONFIG_FILE requires explicit package name at vowCons2.pm line 18. This file has a syntax error due to $CONFIG_FILE being assigned to in a context where it is not defined. Usually this would mean you need to

Re: $CONFIG_FILE

2015-02-20 Thread Kent Fredric
On 21 February 2015 at 02:35, Shawn H Corey shawnhco...@gmail.com wrote: jupiter@jupiter-OptiPlex-755:~/Documents/base-0.50#36; ./base.pl -i words Global symbol #36;CONFIG_FILE requires explicit package name at vowCons2.pm line 18. Go to line 18 of vowCons2.pm and change: #36;CONFIG_FILE

Re: CONFIG_FILE

2015-02-20 Thread Kent Fredric
On 21 February 2015 at 04:29, nicolas nicolas...@mail.com wrote: Global symbol $CONFIG_FILE requires explicit package name at vowCons2.pm line 18. Compilation failed in require at sufpref.pm line 10. BEGIN failed--compilation aborted at sufpref.pm line 10. Compilation failed in require at

Re: Tie::IxHash module

2015-02-19 Thread Kent Fredric
On 20 February 2015 at 09:56, Andy Bach afb...@gmail.com wrote: $ sudo make install Installing to your system with `sudo` is generally not recommended. Ideally you should have a separate perl for user work, or at least a local::lib based overlay set. But these steps can be complicated ...

Re: why is if (! @ARGV) skipped

2014-11-19 Thread Kent Fredric
On 20 November 2014 10:05, Harry Putnam rea...@newsguy.com wrote: , unless I specifically google up some examples of something I believe current advice is not to do that, as there is a vast abundance of very poor/chronically outdated code that may be returned by such a search, or you might

Re: why is if (! @ARGV) skipped

2014-11-18 Thread Kent Fredric
On 19 November 2014 11:46, Harry Putnam rea...@newsguy.com wrote: Only thing I did to debug was to make sure `use File::Find; comes after if (!@ARGV), but that seems not to matter. That will be because 'use' is processed during BEGIN { }, while your condition is during the main execution

Re: using string as module

2014-11-08 Thread Kent Fredric
On 9 November 2014 05:27, Ron Bergin r...@i.frys.com wrote: In fact, I almost never use or suggest using eval. eval itself is not evil. Its just *string* eval becuase that involves arbitrary code interpolation. Non-string eval is of course potentially written as try in other languages (

Re: Yet another first website

2014-11-08 Thread Kent Fredric
On 9 November 2014 05:39, Артём Варнайский varnays...@mail.ru wrote: Also, I have no idea how to design databases. For example, should I store photos separately from the DB or in it? The answer to that question depends on what your database is, and what your demands are with regards to

Re: Yet another first website

2014-11-08 Thread Kent Fredric
On 9 November 2014 05:46, Kent Fredric kentfred...@gmail.com wrote: Because when you need it, you'll know it. Though to counter myself, it proves useful in some places if file IO is problematic or you have security concerns with direct writing to local storage. Though the first of those two

Re: UTF8, UTF-8, utf8, Utf8 encoding blues

2014-11-08 Thread Kent Fredric
On 9 November 2014 05:42, Shlomi Fish shlo...@shlomifish.org wrote: Should work... But the data is simply not correct. It acts as a proxy, so I receive a request, I collect the data from the remote server (capture the packets on the wire with tcpdump), I send the data to the client

Re: share a variable between files

2014-10-08 Thread Kent Fredric
On 9 October 2014 03:35, Hans Ginzel h...@matfyz.cz wrote: Hello! Let's consider following strip-down example: # file a.pl use strict; package a; our $var=1; warn var=$var; # file b.pl use strict; #no strict qw/vars/; require 'b.pl'; package a; warn var=$var; How to get rid of

Re: share a variable between files

2014-10-08 Thread Kent Fredric
On 9 October 2014 08:36, Hans Ginzel h...@matfyz.cz wrote: I want to use one global hash variable for options or configuration variables like verbose, debug. I don't want to pass them to each function or to almost each object. Indeed, Jim Gibson explains you can simply declare our in both

Re: Problem with regex

2014-10-06 Thread Kent Fredric
On 7 October 2014 05:04, punit jain contactpunitj...@gmail.com wrote: it breaks. I tried multiple regex, however could not get it working. Any clue on regex changes to accomodate this ? 1. You said you have a regex, and that you can't get it working, but what is it that isn't working? 2. This

Re: Best way to install perl modules

2014-10-06 Thread Kent Fredric
On 7 October 2014 16:07, Benjamin Fernandis benjo11...@gmail.com wrote: + Attaching log file. Lacking Env.pm basically means your vendor's Perl is broken. Env.pm is shipped with Perl itself, and subsequently things may forget to depend on it ( at least, in a way that cpan tools recognise )

Re: Need to understand what this script does.

2014-08-09 Thread Kent Fredric
On 9 August 2014 16:32, Uday Vernekar vernekaru...@gmail.com wrote: Hi All, please help me in understanding this script. Please explain what it is about this script you want to understand / don't quite understand. Also, if there's something not working in this script, a primary candidate

Re: Suddenly this script is not working!

2014-07-29 Thread Kent Fredric
The script begins: #!/usr/bin/perl use Tie::File; use File::Copy 'copy'; use File::Spec; I think this problem becomes much clearer if you enable strict. -- [ A.pl ] --- my @list = qw( a b c ); print X $list Y; -- [ A.pl output ] -- X Y -- [ B.pl ] -- use strict; my @list = qw( a b

Re: Problem installing a module

2014-07-23 Thread Kent Fredric
On 22 July 2014 06:05, Chris cpoll...@embarqmail.com wrote: I'm not a programmer so I apologize if I'm on the wrong list but I'm looking for some assistance in installing File::Scan::ClamAV. I've tried multiple ways, CPAN and from source, to install this and I constantly get the errors shown

Re: Problem installing a module

2014-07-23 Thread Kent Fredric
On 24 July 2014 02:06, Sam p...@net153.net wrote: Can you post those changes or a link to the mailing list? It might be wise for someone to update the module --Sam Upstream have conferred they want to be released from maintaining it and are looking for somebody take up the mantle.

Re: About staying brushed up on perl

2014-07-22 Thread Kent Fredric
On 20 July 2014 09:33, Harry Putnam rea...@newsguy.com wrote: So all and any ideas, suggestions etc would be well received on this end. One approach that may help is to double down on CPAN. This may reduce the total number of tricks you have to learn, by finding proxies that do the tricks for

CPAN Not installing dependencies ( was: Re: want to write to file in different format )

2014-07-08 Thread Kent Fredric
On 8 July 2014 19:00, Uday Vernekar vernekaru...@gmail.com wrote: when i try to install Path::Tiny it gives me following error # The following REQUIRED prerequisites were not satisfied: # # File::Spec version '3.33' is not in required range '3.40' # t/00-report-prereqs.t . ok

Re: want to write to file in different format

2014-07-07 Thread Kent Fredric
I'm not about to write my own version here, just offer some pointers I find makes life easier for myself, and they may help others too if you're not bound to I don't want to use CPAN. These days, I find it easier and safer to just use use Path::Tiny qw(path); my $infile =

Re: loop does select next line

2014-07-05 Thread Kent Fredric
On 6 July 2014 02:31, Sunita Pradhan sunita.pradhan.2...@hotmail.com wrote: I have a set of code for count number of lines and number of words . #!/usr/bin/perl while ($line = STDIN){ chomp ($line); $hash{L_c_start}++ if ($line =~ /^C.*/i); @words = split