Einzelnen Beitrag anzeigen

Benutzerbild von Neutral General
Neutral General

Registriert seit: 16. Jan 2004
Ort: Bendorf
5.219 Beiträge
 
Delphi 10.2 Tokyo Professional
 
#6

AW: Zwei Ganzzahlen zu Dezimalzahl zusammensetzen

  Alt 28. Sep 2023, 13:26
Mathematische Lösung:
Delphi-Quellcode:
uses
  Math;

function NumbersToFloat(N1, N2: Integer): Double;
begin
  Result := N1 + N2 / Power(10, Floor(Log10(N2) + 1));
end;
Michael
"Programmers talk about software development on weekends, vacations, and over meals not because they lack imagination,
but because their imagination reveals worlds that others cannot see."
  Mit Zitat antworten Zitat