mirror of
https://github.com/adambard/learnxinyminutes-docs.git
synced 2024-12-24 18:11:38 +00:00
Merge pull request #4038 from sburris0/master
[Haskell/en] Explain the !! operator
This commit is contained in:
commit
a990544875
@ -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'
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user