Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number

Re^15: Order in which grep/map receive elements

by BrowserUk (Pope)
on Oct 08, 2012 at 23:03 UTC ( #997893=note: print w/replies, xml ) Need Help??

in reply to Re^14: Order in which grep/map receive elements
in thread Order in which grep/map receive elements

In the interests of nitpicking,

I'm not sure how interesting nitpicking is ;), but if we're going that route ...

implemented using a for loop in C, which does operate in a defined and documented order.

It uses the for loop to pick values off the stack, and return qualifying results to the stack, which then get return to the caller in the stacked order.

Which is no different to what grep does. Albeit that the iteration is split between pp_grepwhile() in pphot.c and pp_grepstart() in pp_ctrl.c.

In the end, it is the fact that the list out is derived -- in sequence -- from the list in, that defines the ordering in both cases.

With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'
Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
"Science is about questioning the status quo. Questioning authority".
In the absence of evidence, opinion is indistinguishable from prejudice.

RIP Neil Armstrong

  • Comment on Re^15: Order in which grep/map receive elements

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://997893]
[Corion]: Hi marto!
[Corion]: I hope you were able to catch up on some sleep
Corion is slowly, slowly relaxing. Yesterday I spent vegging out in front of the PC, today at a friends, and hopefully I have the books for our Perl club done by Monday. I guess I'll only really relax once I get back from LPW
[marto]: last night, well this morning was a 5am finish, up from 4 am the previous day. Oddly I feel better today than I did yesterday
[Corion]: marto: I think the first thing sleep deprivation does is kill your sense of how tired you are :)

How do I use this? | Other CB clients
Other Users?
Others rifling through the Monastery: (7)
As of 2017-11-19 11:25 GMT
Find Nodes?
    Voting Booth?
    In order to be able to say "I know Perl", you must have:

    Results (280 votes). Check out past polls.