convert two ints to one double/float?

Heyho,

I've programmed a stopwatch and display it on a tft display

ofc Im working with millis() and store it into an unsigned long which i convert into an int value:

s=int(elapsed/1000);

ms=int(elapsed%1000);

tft.print(s);

tft.print(".");

tft.println("ms");

for easy display this is a great workaround .... but if i want to log a "best lap" its a bit odd because i would need to check both integers and calc the difference seperatley.... is there a way i could convert the displayed value to a single double or float?

is there a way i could convert the displayed value to a single double or float?

Why not keep the original unsigned long in a variable and compare that ?

Display the elapsed time in seconds.milliseconds:
Serial.println( (float)elapsed/1000.0,3);

jremington:
Display the elapsed time in seconds.milliseconds:
Serial.println( (float)elapsed/1000.0,3);

worked !thanks a lot!