ListMap3FloatTripleSumTest
`List.map3` on three `List Float`s passes the Float elements unchanged to the mapping function; the sums equal `[ 111.0, 222.0 ]`.
Results
elm-0.19.1
passran in 74 msOutput
Compiled in DEV mode. Follow the advice at https://elm-lang.org/0.19.1/optimize for better performance and smaller assets. result: [111,222] match: True
elm-0.19.2
passran in 45 msOutput
Compiled in DEV mode. Follow the advice at https://elm-lang.org/0.19.2/optimize for better performance and smaller assets. result: [111,222] match: True
elm-0.19.3
passran in 68 msOutput
Compiled in DEV mode. Follow the advice at https://elm-lang.org/0.19.3/optimize for better performance and smaller assets. result: [111,222] match: True
lamdera-1.5.0
passran in 59 msOutput
result: [111,222] match: True
Discussions
Discuss this test·Search the discussions on GitHub
Discussions are on GitHub; one about this test has [t:elm-core/ListMap3FloatTripleSumTest] in its title.
Source
The -- CHECK: lines give the expected output.
module ListMap3FloatTripleSumTest exposing (main)
{-| `List.map3` on three `List Float`s passes the Float elements unchanged to the
mapping function; the sums equal `[ 111.0, 222.0 ]`.
-}
-- CHECK: result: [111,222]
-- CHECK: match: True
import Html exposing (text)
main =
let
result =
List.map3 (\a b c -> a + b + c) [ 1.0, 2.0 ] [ 10.0, 20.0 ] [ 100.0, 200.0 ]
_ =
Debug.log "result" result
_ =
Debug.log "match" (result == [ 111.0, 222.0 ])
in
text "done"