diff options
Diffstat (limited to 'rust/lucians-luscious-lasagna')
-rw-r--r-- | rust/lucians-luscious-lasagna/src/lib.rs | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/rust/lucians-luscious-lasagna/src/lib.rs b/rust/lucians-luscious-lasagna/src/lib.rs index 19da8d3..06ea99a 100644 --- a/rust/lucians-luscious-lasagna/src/lib.rs +++ b/rust/lucians-luscious-lasagna/src/lib.rs @@ -1,11 +1,15 @@ -pub fn expected_minutes_in_oven() -> i32 { 40 } +pub fn expected_minutes_in_oven() -> i32 { + const EXPECTED_TIME: i32 = 40; + EXPECTED_TIME +} pub fn remaining_minutes_in_oven(actual_minutes_in_oven: i32) -> i32 { expected_minutes_in_oven() - actual_minutes_in_oven } pub fn preparation_time_in_minutes(number_of_layers: i32) -> i32 { - number_of_layers * 2 + const TIME_REQUIRED_FOR_A_LAYER: i32 = 2; + number_of_layers * TIME_REQUIRED_FOR_A_LAYER } pub fn elapsed_time_in_minutes(number_of_layers: i32, |