Ad
  • Default User Avatar

    The same task with different starting and ending times would need to give those times as argument.
    The question is then what format use? Integer hour, Integer minutes, String, ... ?

    There's no point in making a function for any start and end when there's no specification about it, you would most likely have to rework the thing anyway.

    The function takes barely 1 or 2 minutes to write, if it has to be remake you didn't lose much.
    But if you write it to work as you said and the specification doesn't change then you lost way more time.