mirror of
https://codeberg.org/andyscott/ziglings.git
synced 2024-12-22 14:03:10 -05:00
15 lines
418 B
Diff
15 lines
418 B
Diff
--- exercises/034_quiz4.zig 2023-10-03 22:15:22.122241138 +0200
|
|
+++ answers/034_quiz4.zig 2023-10-05 20:04:06.996099091 +0200
|
|
@@ -9,10 +9,10 @@
|
|
|
|
const NumError = error{IllegalNumber};
|
|
|
|
-pub fn main() void {
|
|
+pub fn main() !void {
|
|
const stdout = std.io.getStdOut().writer();
|
|
|
|
- const my_num: u32 = getNumber();
|
|
+ const my_num: u32 = try getNumber();
|
|
|
|
try stdout.print("my_num={}\n", .{my_num});
|
|
}
|