From a5e41335161601acc3e86e0b9425c66c9af354c3 Mon Sep 17 00:00:00 2001 From: Jon Erling Hustadnes Date: Fri, 8 Sep 2023 16:42:16 +0200 Subject: [PATCH] Make primitive_types3 require at least 100 elements Made the function panic if it's not long enough --- exercises/primitive_types/primitive_types3.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/exercises/primitive_types/primitive_types3.rs b/exercises/primitive_types/primitive_types3.rs index 06a7a62..8b0de44 100644 --- a/exercises/primitive_types/primitive_types3.rs +++ b/exercises/primitive_types/primitive_types3.rs @@ -14,5 +14,6 @@ fn main() { println!("Wow, that's a big array!"); } else { println!("Meh, I eat arrays like that for breakfast."); + panic!("Array not big enough, more elements needed") } }