Hello,
Our system value for decimal separator is the comma. In our RPGLE programs, we use DECEDIT('0,'). However, we can code both using commas and periods.
Both give 50.01 (in debug, it uses periods to show decimals even though the job has comma as the decimal separator. Why that is, is another question.).
Both give 51.01.
I tried doing
just to see but got compile errors.
We only need/want the comma to be used as the decimal separator. How is it we can also use the period?
Our system value for decimal separator is the comma. In our RPGLE programs, we use DECEDIT('0,'). However, we can code both using commas and periods.
Code:
SumComma = 50 + 0,01; SumPeriod = 50 + 0.01;
Code:
SumComma = 50 + 1,01; SumPeriod = 50 + 1.01;
I tried doing
Code:
SumPeriod = 50 + 1.000,01;
We only need/want the comma to be used as the decimal separator. How is it we can also use the period?
Comment