Need help DS18B20 max and min temp

Hello! HW: Arduino Mega, Ethernet Shield, 2xDs18b20, LCD Display SW: Web server on Arduino, output on web server current temp in home and in garden.

How can I take the maximum and minimum temperature for the 24 hours ???

Initialise min and max to the current temperature.

Re-read current temperature. If less than min, set min to current temperature. If more than max, set max to the current temperature. Repeat until 24 hours have passed.

Thank you! But how can this be in the code?

Samodelkin: Thank you! But how can this be in the code?

Do you understand the algorithm I described? Which part of this are you having trouble coding? Have you made any attempt to code it?

If your question is really 'please write the code for me' then no, I'm not going to do that. But if you have made a sincere attempt to solve the problem yourself and are stuck, then I'm happy to help you get unstuck.

PeterH, thanks I has understood how to write code, that is very easy! Topic can be closed))

Can you write you code here ? Thanks