exc. 34 migrated

This commit is contained in:
Chris Boesch
2025-12-28 14:46:23 +01:00
parent 8e30debc6a
commit 8f9daa12b2
2 changed files with 10 additions and 7 deletions

View File

@@ -6,15 +6,17 @@
// my_num=42
//
const std = @import("std");
const io = std.Options.debug_io;
const NumError = error{IllegalNumber};
pub fn main() void {
var stdout = std.fs.File.stdout().writer(&.{});
var stdout_writer = std.Io.File.stdout().writer(io, &.{});
const stdout = &stdout_writer.interface;
const my_num: u32 = getNumber();
try stdout.interface.print("my_num={}\n", .{my_num});
try stdout.print("my_num={}\n", .{my_num});
}
// This function is obviously weird and non-functional. But you will not be changing it for this quiz.