in reply to Seemingly odd behavior of sequence

The expression 0..9 x 2 evaluates as 0 .. (9 x 2). Put parentheses around the range op:
print +(0..9) x 2, "\n";
See perlop for the list of operator precedences. Hmm, or perlop (man page).
The table appears somewhat mangled on [doc://perlop].

Replies are listed 'Best First'.
Re^2: Seemingly odd behavior of sequence
by jar00n (Novice) on Dec 05, 2013 at 09:43 UTC
    Thanks for the reply, I figured that was happening in a moment of genius in the shower... "What if the 'x' operator has a higher precedence than the sequence expansion?"