class HoursMinutesSeconds {
  late int _days;
  late int _hours;
  late int _mins;
  late int _secs;

  HoursMinutesSeconds(int totalSeconds) {
    _days = (totalSeconds / 86400).floor();
    int daysInSec = _days * 86400;
    _hours = ((totalSeconds - daysInSec) / 3600).floor();
    int hoursInSec = (_hours * 3600);
    _mins = ((totalSeconds - daysInSec - hoursInSec) / 60).floor();
    int minsInSec = _mins * 60;
    _secs = totalSeconds - minsInSec - hoursInSec - daysInSec;
  }

  int getSeconds() {
    return _secs;
  }

  int getMinutes() {
    return _mins;
  }

  int getHours() {
    return _hours;
  }

  int getDays() {
    return _days;
  }
}
