[Date Prev][Date Next][Thread Prev][Thread Next]
[Author Index]
[Date Index]
[Thread Index]
[SQR-USERS Info]
[SQRUG Home Page]
Re: [sqr-users] Fetching value from 2-Dim. Array
Agreed, as a set of programmers we should certainly avoid using a hyphen in
variable names, but the language should not allow it. OR at the very least
give warnings if the value following the hyphen is numeric. After all, if I
say this in c++:
char x;
int y;
x = y;
It will let you do it but you will get a warning that significant digits may be
lost. That at least gives you something to go back to if the program operates
oddly.
At this point there are other bugs in SQR that I would push to get resolved
first, however - such as the phantom digits in the far reaches of floating
point variables.
******************************
Larry Roux
Syracuse University
lroux@syr.edu
*******************************
>>> ceprn@hotmail.com 11/30/03 11:54 AM >>>
Ray,
I agree, but if everyone understood this (hint, hint losers at PEOPLESOFT),
and used only underscores in their variable names (good coding practice for
exactly this reason), then it wouldn't be as much of an issue.
clark
PSA: Salary <> Slavery. If you earn a salary, your employer is renting your
services for 40 hours a week, not purchasing your soul. Your time is the
only real finite asset that you have, and once used it can never be
recovered, so don't waste it by giving it away.
"Time is the coin of your life. It is the only coin you have, and only you
can determine how it will be spent. Be careful lest you let other people
spend it for you."
Carl Sandburg
(1878 - 1967)
----Original Message Follows----
Sudeep,
"#count-1" is the name of a variable, not the value of an
expression. In the while loop where you reference the array
element you refer to:
WeekEndingArray.WeekEnding(0,#count-1)
You should change this to:
WeekEndingArray.WeekEnding(0,#count - 1)
Since the variable "#count-1" was never given a value, it has
the value of zero.
One of my few complaints about SQR is that it allows a "-" in
variable names.
Ray
_________________________________________________________________
>From the hottest toys to tips on keeping fit this winter, you'll find a
range of helpful holiday info here.
http://special.msn.com/network/happyholidays.armx
_______________________________________________
sqr-users mailing list
sqr-users@sqrug.org
http://www.sqrug.org/mailman/listinfo/sqr-users
_______________________________________________
sqr-users mailing list
sqr-users@sqrug.org
http://www.sqrug.org/mailman/listinfo/sqr-users