2020-12-23 12:02:35 -05:00
|
|
|
//
|
2023-05-04 19:04:58 -04:00
|
|
|
// Oh no, this is supposed to print "Hello world!" but it needs
|
|
|
|
// your help.
|
2020-12-23 12:02:35 -05:00
|
|
|
//
|
2023-05-04 19:04:58 -04:00
|
|
|
// Zig functions are private by default but the main() function
|
|
|
|
// should be public.
|
2021-02-15 16:55:44 -05:00
|
|
|
//
|
2023-05-04 19:04:58 -04:00
|
|
|
// A function is made public with the "pub" statement like so:
|
2021-02-07 11:06:51 -05:00
|
|
|
//
|
|
|
|
// pub fn foo() void {
|
|
|
|
// ...
|
|
|
|
// }
|
|
|
|
//
|
2023-05-06 17:38:13 -04:00
|
|
|
// Perhaps knowing this will help solve the errors we're getting
|
2023-05-04 19:04:58 -04:00
|
|
|
// with this little program?
|
2020-12-23 12:02:35 -05:00
|
|
|
//
|
2021-01-03 12:21:11 -05:00
|
|
|
const std = @import("std");
|
2020-12-23 12:02:35 -05:00
|
|
|
|
2024-01-10 02:52:58 -05:00
|
|
|
pub fn main() void {
|
2021-01-03 12:21:11 -05:00
|
|
|
std.debug.print("Hello world!\n", .{});
|
2020-12-23 12:02:35 -05:00
|
|
|
}
|