in reply to Re^12: chopping a string into slices - is there a more elegant way to do it?
in thread chopping a string into slices - is there a more elegant way to do it?

Do you know any perlcode, where () and (1,2) reacts as a list and (1) does not???

My point is that parens have nothing to do with it, so I'm not sure what you are trying to prove.

Do you know any perlcode where 1,2 reacts as a list and 1 does not?

Replies are listed 'Best First'.
Re^14: chopping a string into slices - is there a more elegant way to do it?
by LanX (Saint) on Dec 01, 2008 at 14:07 UTC
    > so I'm not sure what you are trying to prove.

    I'm trying to find a resonable simple model to understand perl's syntax!

    Thumbrules which are alway true!

    Kind of "Ducktyping" where the opcode details do not matter!

    With other words: Do you really want to tell a beginner that parens on LHS make "=" act like aassign instead of sassign???

    do you understand me now?

    Cheers Rolf

      I say "parens force a list assignment", not "parens force a list".

      The concepts are already simple. I don't need to make up rules to keep it simple. That only leads to making up more rules on the fly.

        > The concepts are already simple.

        simple != trivial

        If it is really inevitable to teach opcode mechanisms, it's perfectly understandable when people prefer learning languages like python or ruby...

        Cheers Rolf