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-04 19:04:58 -04:00
|
|
|
// Perhaps knowing this well help solve the errors we're getting
|
|
|
|
// 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
|
|
|
|
2021-01-03 12:21:11 -05:00
|
|
|
fn main() void {
|
|
|
|
std.debug.print("Hello world!\n", .{});
|
2020-12-23 12:02:35 -05:00
|
|
|
}
|