Commit 8f081b64 by mnislaih

### Update the users_guide regarding list notation in :print

parent 71e037d1
 ... @@ -1244,9 +1244,9 @@ li - (_t1::[Maybe Integer]) ... @@ -1244,9 +1244,9 @@ li - (_t1::[Maybe Integer]) Prelude> head li Prelude> head li Just 1 Just 1 Prelude> :sp li Prelude> :sp li li - [Just 1 | _] li - Just 1 : _ Prelude> :p li Prelude> :p li li - [Just 1 | (_t2::[Maybe Integer])] li - Just 1 : (_t2::[Maybe Integer]) Prelude> last li Prelude> last li Just 5 Just 5 Prelude> :sp li Prelude> :sp li ... @@ -1262,8 +1262,6 @@ li - [Just 1,(_t6::Maybe Integer),Just 3,(_t7::Maybe Integer),Just 4] ... @@ -1262,8 +1262,6 @@ li - [Just 1,(_t6::Maybe Integer),Just 3,(_t7::Maybe Integer),Just 4] to help us observe how the li variable is evaluated progressively as we operate to help us observe how the li variable is evaluated progressively as we operate with it. Note for instance how last traverses all the elements of with it. Note for instance how last traverses all the elements of the list to compute its result, but without evaluating the individual elements. the list to compute its result, but without evaluating the individual elements. Finally note that the Prolog convention of [head | tail] is used by :sprint to display unevaluated lists. ... @@ -1389,7 +1387,7 @@ li - _ ... @@ -1389,7 +1387,7 @@ li - _ Prelude> head li Prelude> head li Just 1 Just 1 Prelude> :sp li Prelude> :sp li li - [Just 1 | _] li - Just 1 : _ Prelude> last li Prelude> last li Just 5 Just 5 Prelude> :sp li Prelude> :sp li ... @@ -1398,8 +1396,6 @@ li - [Just 1,_,_,_,Just 5] ... @@ -1398,8 +1396,6 @@ li - [Just 1,_,_,_,Just 5] The example uses :sprint to help us observe how the li variable is evaluated progressively as we operate The example uses :sprint to help us observe how the li variable is evaluated progressively as we operate with it. Note for instance how last traverses all the elements of with it. Note for instance how last traverses all the elements of the list to compute its result, but without evaluating the individual elements. the list to compute its result, but without evaluating the individual elements. Finally note that the Prolog convention of [head | tail] is used by :sprint to display unevaluated lists. ... ...
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!