From f70130322cd306268c5da12c1517dc5725615ae8 Mon Sep 17 00:00:00 2001 From: Louis Pilfold Date: Thu, 15 Feb 2024 12:18:17 +0000 Subject: text -> en --- .../lesson01_case_expressions/en.html | 18 ++++++++++++++++++ .../lesson01_case_expressions/text.html | 18 ------------------ 2 files changed, 18 insertions(+), 18 deletions(-) create mode 100644 src/content/chapter2_flow_control/lesson01_case_expressions/en.html delete mode 100644 src/content/chapter2_flow_control/lesson01_case_expressions/text.html (limited to 'src/content/chapter2_flow_control/lesson01_case_expressions') diff --git a/src/content/chapter2_flow_control/lesson01_case_expressions/en.html b/src/content/chapter2_flow_control/lesson01_case_expressions/en.html new file mode 100644 index 0000000..07ff421 --- /dev/null +++ b/src/content/chapter2_flow_control/lesson01_case_expressions/en.html @@ -0,0 +1,18 @@ +

+ The case expression is the most common kind of flow control in Gleam code. It + is similar to switch in some other languages, but more powerful + than most. +

+

+ It allows the programmer to say "if the data has this shape then run this + code", a process called pattern matching. +

+

+ Gleam performs exhaustiveness checking to ensure that the patterns in + a case expression cover all possible values. With this you can have confidence + that your logic is up-to-date for the design of the data you are working with. +

+

+ Try commenting out patterns or adding new redundant ones, and see what + problems the compiler reports. +

diff --git a/src/content/chapter2_flow_control/lesson01_case_expressions/text.html b/src/content/chapter2_flow_control/lesson01_case_expressions/text.html deleted file mode 100644 index 07ff421..0000000 --- a/src/content/chapter2_flow_control/lesson01_case_expressions/text.html +++ /dev/null @@ -1,18 +0,0 @@ -

- The case expression is the most common kind of flow control in Gleam code. It - is similar to switch in some other languages, but more powerful - than most. -

-

- It allows the programmer to say "if the data has this shape then run this - code", a process called pattern matching. -

-

- Gleam performs exhaustiveness checking to ensure that the patterns in - a case expression cover all possible values. With this you can have confidence - that your logic is up-to-date for the design of the data you are working with. -

-

- Try commenting out patterns or adding new redundant ones, and see what - problems the compiler reports. -

-- cgit v1.2.3