From 8af3372cf204861f8541f91e47543f1b33337c5b Mon Sep 17 00:00:00 2001 From: Chris Boesch Date: Mon, 4 May 2026 17:15:30 +0200 Subject: fixed removed array multiplication --- exercises/075_quiz8.zig | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'exercises/075_quiz8.zig') diff --git a/exercises/075_quiz8.zig b/exercises/075_quiz8.zig index 63d208b..08270ee 100644 --- a/exercises/075_quiz8.zig +++ b/exercises/075_quiz8.zig @@ -48,9 +48,7 @@ const Path = struct { // instead. // // Please fill in the body of this function! -fn makePath(from: *Place, to: *Place, dist: u8) Path { - -} +fn makePath(from: *Place, to: *Place, dist: u8) Path {} // Using our new function, these path definitions take up considerably less // space in our program now! @@ -97,7 +95,7 @@ const NotebookEntry = struct { }; const HermitsNotebook = struct { - entries: [place_count]?NotebookEntry = .{null} ** place_count, + entries: [place_count]?NotebookEntry = @splat(null), next_entry: u8 = 0, end_of_entries: u8 = 0, @@ -193,7 +191,7 @@ pub fn main() void { } } - var trip = [_]?TripItem{null} ** (place_count * 2); + var trip: [place_count * 2]?TripItem = @splat(null); notebook.getTripTo(trip[0..], destination) catch |err| { print("Oh no! {}\n", .{err}); -- cgit v1.2.3