From fa032fb85bddf3c5cd692325d14e274433390da9 Mon Sep 17 00:00:00 2001 From: Jonas Zitzmann Date: Thu, 8 Feb 2024 18:34:56 +0100 Subject: [PATCH] add new converter: hour to sec --- src/convert_time.c | 5 +++++ src/convert_time.h | 1 + 2 files changed, 6 insertions(+) diff --git a/src/convert_time.c b/src/convert_time.c index 36b9599..726ca28 100644 --- a/src/convert_time.c +++ b/src/convert_time.c @@ -18,4 +18,9 @@ double converter_hour_to_min(double hour){ double converter_min_to_hour(double min){ double time = min / 60; return time; +} + +double converter_hour_in_sec(double hour){ + double time = hour * 60 * 60; + return time; } \ No newline at end of file diff --git a/src/convert_time.h b/src/convert_time.h index e48117f..56301fa 100644 --- a/src/convert_time.h +++ b/src/convert_time.h @@ -5,5 +5,6 @@ double converter_sec_to_min(double sec); double converter_min_to_sec(double min); double converter_hour_to_min(double hour); double converter_min_to_hour(double min); +double converter_hour_in_sec(double hour); #endif //THEADMIRALS_CONVERT_TIME_H