From 5257941f40554da3f8df074443a4c087dcff7004 Mon Sep 17 00:00:00 2001 From: Martin Ashby Date: Sat, 10 Dec 2022 23:02:40 +0000 Subject: 25-60 complete --- exercises/044_quiz5.zig | 2 ++ 1 file changed, 2 insertions(+) (limited to 'exercises/044_quiz5.zig') diff --git a/exercises/044_quiz5.zig b/exercises/044_quiz5.zig index 8a0d88c..3e6ee79 100644 --- a/exercises/044_quiz5.zig +++ b/exercises/044_quiz5.zig @@ -19,12 +19,14 @@ const Elephant = struct { pub fn main() void { var elephantA = Elephant{ .letter = 'A' }; // (Please add Elephant B here!) + var elephantB = Elephant{ .letter = 'B' }; var elephantC = Elephant{ .letter = 'C' }; // Link the elephants so that each tail "points" to the next elephant. // They make a circle: A->B->C->A... elephantA.tail = &elephantB; // (Please link Elephant B's tail to Elephant C here!) + elephantB.tail = &elephantC; elephantC.tail = &elephantA; visitElephants(&elephantA); -- cgit v1.2.3-ZIG