From bdfe3df2947f8787c8a4ef8c534f6a8932e13871 Mon Sep 17 00:00:00 2001 From: Ibrahim Muftee Date: Mon, 29 Jun 2026 15:11:40 -0500 Subject: feat: begin solving exercises --- exercises/037_structs.zig | 2 ++ 1 file changed, 2 insertions(+) (limited to 'exercises/037_structs.zig') diff --git a/exercises/037_structs.zig b/exercises/037_structs.zig index c345faf..a7a9a2f 100644 --- a/exercises/037_structs.zig +++ b/exercises/037_structs.zig @@ -33,6 +33,7 @@ const Role = enum { // Please add a new property to this struct called "health" and make // it a u8 integer type. const Character = struct { + health: u8, role: Role, gold: u32, experience: u32, @@ -41,6 +42,7 @@ const Character = struct { pub fn main() void { // Please initialize Glorp with 100 health. var glorp_the_wise = Character{ + .health = 100, .role = Role.wizard, .gold = 20, .experience = 10, -- cgit v1.2.3