P
pingbaoshi
Unregistered / Unconfirmed
GUEST, unregistred user!
procedure TForm1.Button1Click(Sender: TObject);
var str1:string;
m:double;
begin
m:=1.275;
Str1:=Format('%5.2f',[1.275]);
showmessage(str1);
Str1:=Format('%5.2f',[m]);
showmessage(str1);
end;
大家看看,结果为何不同哪?
一个1.27,一个1.28
var str1:string;
m:double;
begin
m:=1.275;
Str1:=Format('%5.2f',[1.275]);
showmessage(str1);
Str1:=Format('%5.2f',[m]);
showmessage(str1);
end;
大家看看,结果为何不同哪?
一个1.27,一个1.28