in reply to Re^2: Getting different results with $var++ and $var += 1
in thread Getting different results with $var++ and $var += 1
What I suggest is that you reduce your code to a minimal program such that it 1) runs, and 2) shows your problem.
Under what conditions can I take a string "110.98" and not be able to use it in numeric context? I thought the answer was "under no conditions ever for any reason under any version of Perl" but clearly I'm wrong.Oh, no, you are right. If you have a string "110.98", you will be able to use it in numeric context. The problem however is that you may very well have some else than a string.
But since we don't know where the thing you have is coming from, we don't know, do we? And I don't like the game of "I've problem. I only half describe it. Now guess what's going on". If I want to play situation puzzles, I'll go to rec.puzzles.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^4: Getting different results with $var++ and $var += 1
by splicer (Novice) on Dec 04, 2008 at 01:24 UTC |