Python Forum
Hello all! need help. calculating OT hours.
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Hello all! need help. calculating OT hours.
#3
I'd use float instead of int. I want to get paid for my entire 2.5 hours of overtime.

I would not use if or else to solve this problem. I would use min and max.

The most common error I see with this problem forgetting that overtime rates are only applied to overtime hours and regular rates to regular hours. No double dipping!
Reply


Messages In This Thread
RE: Hello all! need help. calculating OT hours. - by deanhystad - Jul-30-2022, 05:00 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  MatplotibTicks every 24 hours TamP 4 1,257 Oct-04-2022, 04:08 PM
Last Post: deanhystad
  Py script that triggers ever 3 hours, but only between 9:15 am to 3:30 pm, Mon to Fri Pymod 2 1,902 Jun-30-2021, 05:14 PM
Last Post: Larz60+
  How to get utcnow + 2 hours? korenron 2 2,662 Mar-01-2021, 03:22 PM
Last Post: korenron
  Need to add hours min and seconds tester_V 5 3,202 Jun-02-2020, 05:29 PM
Last Post: tester_V

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020