Skip to content

Commit

Permalink
Fix magician in training introduction (#612)
Browse files Browse the repository at this point in the history
* Fix import example

* Fix link to default imports
  • Loading branch information
ThunderKey authored Oct 13, 2023
1 parent 2b3423e commit f01b6f6
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions concepts/array/about.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ There is no literal syntax for arrays (like there is for list), so instead the A
For example, an `Array` with "a", "b" and "c" in it is usually shown as `Array.fromList ["a", "b", "c"]`.
You will see this on console output, in the debugger, and other places like that.

Unlike `List` which is a [default-import][default import], the `Array` module must be explicity imported, using `import Array` or similar.
Unlike `List` which is a [default-import][default-imports], the `Array` module must be explicity imported, using `import Array` or similar.

Type annotations for lists can be defined as follows

Expand All @@ -18,7 +18,7 @@ Array Int --> an array of Int
Arrays can be defined as follows:

```elm
import Array exposing Array
import Array exposing (Array)

empty : Array Char
empty = Array.empty
Expand Down
4 changes: 2 additions & 2 deletions concepts/array/introduction.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@

An [`Array`][array] in Elm is a fast immutable collection of zero or more values of the same type.

Unlike `List` which is a [default-import][default import], the `Array` module must be explicity imported, using `import Array` or similar.
Unlike `List` which is a [default-import][default-imports], the `Array` module must be explicity imported, using `import Array` or similar.

Arrays can be defined as follows:

```elm
import Array exposing Array
import Array exposing (Array)

empty : Array Char
empty = Array.empty
Expand Down
6 changes: 3 additions & 3 deletions exercises/concept/magician-in-training/.docs/introduction.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,12 @@

An [`Array`][array] in Elm is a fast immutable collection of zero or more values of the same type.

Unlike `List` which is a [default-import][default import], the `Array` module must be explicity imported, using `import Array` or similar.
Unlike `List` which is a [default-import][default-imports], the `Array` module must be explicity imported, using `import Array` or similar.

Arrays can be defined as follows:

```elm
import Array exposing Array
import Array exposing (Array)

empty : Array Char
empty = Array.empty
Expand All @@ -33,7 +33,7 @@ oneToFour = Array.push 1 twoToFour --> Array.fromList [ 1, 2, 3, 4 ]
An element in an Array is retrieved using `Array.get`:

```elm
sixSeven = Array.fromList [ 6, 7 ]
sixSeven = Array.fromList [ 6, 7 ]
Array.get 0 sixSeven --> Just 6
```

Expand Down

0 comments on commit f01b6f6

Please sign in to comment.