Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl Monk, Perl Meditation

Re: Using grep in a scalar context

by spandox (Novice)
on Feb 06, 2013 at 13:38 UTC ( #1017432=note: print w/ replies, xml ) Need Help??

in reply to Using grep in a scalar context

$FMat[0][0]=scalar(grep(/AA/, @dipept));

Comment on Re: Using grep in a scalar context
Download Code
Replies are listed 'Best First'.
Re^2: Using grep in a scalar context
by choroba (Canon) on Feb 07, 2013 at 15:18 UTC
    Scalar context is created by the type of the lvalue in assignments. Adding scalar here does nothing - the scalar context is already there.
    لսႽ ᥲᥒ⚪⟊Ⴙᘓᖇ Ꮅᘓᖇ⎱ Ⴙᥲ𝇋ƙᘓᖇ
      :) it is unambiguous, and hurts nothing

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1017432]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others pondering the Monastery: (8)
As of 2015-11-30 03:56 GMT
Find Nodes?
    Voting Booth?

    What would be the most significant thing to happen if a rope (or wire) tied the Earth and the Moon together?

    Results (757 votes), past polls