siri isha wrote:
> Hi
> I have a small doubt regarding perl. Can please help me out...
> 
> Usually in perl to count the occurance of a specific variable in the input
> we will use "count".
>  I want to know whether we can assign differnt variables and can be able to
>  count the total no of that variables in the input...
> 
>  EXAMPLE:
>        m_sites  =  ' ggwxy ',  ' ggvtew ', '  gyhtdj ' , ' hhhwqr ' .
>  i want to know what we can do to count the total no of m_sites in the
>  input

That's pretty cryptic.  Is m_sites supposed to be a Perl vrbl (ie: $m_sites)
or maybe a config file line ?

If it's a Perl vrbl, you could do a split on /\s*,\s*/ and the array size
would be your count.

Better to post actual code than some strange looking example as above.
_______________________________________________
ActivePerl mailing list
[email protected]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
  • perl siri isha
    • Re: perl Bill Luebkert

Reply via email to