Well, I'm not sure if it's all that frustrating honestly. You've come up with a unique way of dealing with your data, you shouldn't really expect Perl to know what you mean unless you tell it. When dealing with scalars, Perl has a relatively limited set of things that it aims to do. Basically it will try to "Do What You Mean". So if you're are doing arithmetic operations, it will try to interpret your variable as a number even if it is current a string holder "nil".
One way around this issue would be to make your data into a class and then overload the mathematical operaters. Another way would be to create a class that you can tie to those scalars. But those are just ways of extrapolating the logic into a single location to simplify things. You still need to create the logic though.
- Miller