in reply to Perl Concatenate vs Append Operator
Neither is more correct than the other. TMTOWTDI, that's all.
I prefer to use the assignment operators because I think they're more intuitive and more idiomatic. And I prefer auto-increment and auto-decrement to the assignment operators. So I'd do this…
$total_days++;
…instead of this…
$total_days += 1;
…and I'd never do this…
$total_days = $total_days + 1;
UPDATE: I concur with Your Mother's remarks about the concatenation operator. I hardly ever use it. In most cases, there's a better way to accomplish one's string-building tasks using other methods, particularly join().
|
|---|