summaryrefslogtreecommitdiffhomepage
path: root/haskell.html.markdown
diff options
context:
space:
mode:
authorSpencer Burris <sburris@posteo.net>2020-10-15 12:29:37 -0700
committerSpencer Burris <sburris@posteo.net>2020-10-15 12:34:01 -0700
commitaa8d8e408a8d9cce66de273a8689a9e38d9f5134 (patch)
tree0df767e5b0b0d0a6da88f90f9ddb587ffabb47b2 /haskell.html.markdown
parent33cd1f57ef49f4ed0817e906b7579fcf33c253a1 (diff)
[Haskell/en] Explain the !! operator
Diffstat (limited to 'haskell.html.markdown')
-rw-r--r--haskell.html.markdown2
1 files changed, 2 insertions, 0 deletions
diff --git a/haskell.html.markdown b/haskell.html.markdown
index 1cc79ec9..328da5c9 100644
--- a/haskell.html.markdown
+++ b/haskell.html.markdown
@@ -61,6 +61,8 @@ not False -- True
-- A string is a list of characters
['H', 'e', 'l', 'l', 'o'] -- "Hello"
+
+-- Lists can be indexed with the `!!` operator followed by an index
"This is a string" !! 0 -- 'T'