From 1e15f4ab689ed57980099919030c8965fe1ccffa Mon Sep 17 00:00:00 2001 From: Louis Pilfold Date: Thu, 18 Jan 2024 19:23:44 +0000 Subject: Rename lesson --- .../chapter0_basics/lesson01_hello_world/code.gleam | 7 +++++++ .../chapter0_basics/lesson01_hello_world/text.html | 17 +++++++++++++++++ 2 files changed, 24 insertions(+) create mode 100644 src/content/chapter0_basics/lesson01_hello_world/code.gleam create mode 100644 src/content/chapter0_basics/lesson01_hello_world/text.html (limited to 'src/content/chapter0_basics/lesson01_hello_world') diff --git a/src/content/chapter0_basics/lesson01_hello_world/code.gleam b/src/content/chapter0_basics/lesson01_hello_world/code.gleam new file mode 100644 index 0000000..67cc6b4 --- /dev/null +++ b/src/content/chapter0_basics/lesson01_hello_world/code.gleam @@ -0,0 +1,7 @@ +// Import a Gleam module from the standard library +import gleam/io + +pub fn main() { + // Print to the console + io.println("Hello, Joe!") +} diff --git a/src/content/chapter0_basics/lesson01_hello_world/text.html b/src/content/chapter0_basics/lesson01_hello_world/text.html new file mode 100644 index 0000000..8e2033a --- /dev/null +++ b/src/content/chapter0_basics/lesson01_hello_world/text.html @@ -0,0 +1,17 @@ +

+ Here is a program that prints out the text "Hello, Joe!". +

+

+ It does this by using the `println` function which has been imported from the + gleam/io + module, which is part of the Gleam standard library. +

+

+ In a normal Gleam program this program would be run use the command + gleam run on the command line, but here in this tutorial the + program is automatically compiled and run as the code is edited. +

+

+ Try changing the text being printed to Hello, Mike! and see what + happens. +

-- cgit v1.2.3