I have a problem subtracting hours after 24 hours, the result is negative

Usually in various tools I solve it this way HOUR(24+Hour End -Hour Start) + Minute(24+Hour End -Hour Start)/60.

This gives me the duration or difference regardless of the time example: 23:00PM - 01Am = 2 hours with this formula.

But in appsheet that same logic doesn’t work for me, is there any other way to do it?

Formula use on appsheet = HOUR(24+[HORA TERMINO]-[HORA INICIO])+MINUTE(24+[HORA TERMINO]-[HORA INICIO])/60