Thanks, but that's exactly what I'am doing...misof wrote:var x : double;kp wrote:I see...
Does anybody know how to use
such routines as printf("%.2f") in PASCAL?
I believe Format() is restricted ?!
x := 1.2345;
writeln(x:0:2); { 0 is the total # of chars (if non-zero, aligns right), 2 is the # of decimal places }
BTW, I figured out one more thing. Code:
x:= 130.125;
writeln(x:0:2);
gives 130.13 if compiled with Delphi (my native compiler)
but gives 130.12 if compiled with FreePascal
So, what I see is not what I get

Will try to get AC...