Skip to content
This repository was archived by the owner on Feb 20, 2022. It is now read-only.

Commit 240da1a

Browse files
author
José Valim
committed
Show code comment syntax and basic data types before moving on
1 parent a205166 commit 240da1a

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

README.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,18 @@ iex> 40 + 2
4040
42
4141
iex> "hello" <> " world"
4242
"hello world"
43+
iex> # This is a code comment
44+
nil
45+
```
46+
47+
Besides numbers and strings above, we also use frequently the following data types:
48+
49+
```iex
50+
iex> :atom # An identifier (known as Symbols in other languages)
51+
:atom
52+
iex> [1, 2, "three"] # Lists (can hold any item)
53+
[1, 2, "three"]
54+
iex> {:ok, "value"} # Tuples (can hold any item)
4355
```
4456

4557
Once we finish our portal application, we expect to be able to type the following code inside `iex`:

0 commit comments

Comments
 (0)