in reply to Re: precedence question
in thread precedence question
My question is, since the assignment is made to the scalar variable $a using += and -= at supposedly different times, which parentheses is evaluated first? Or are they evaluated at the same time? I know there are different ways to do this; this is a kind of "What is the philosophy of Perl on this situation?" type of question, because I was curious. The possible answers I can see are:#!/usr/bin/perl $a = 10; $result = ($a+=5) + ($a-=10); print "$result";
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Re: precedence question
by waswas-fng (Curate) on Aug 09, 2002 at 22:10 UTC | |
by Aron (Initiate) on Aug 09, 2002 at 22:48 UTC |