Files
newt/tests/ListSugar.newt
Steve Dunham 4814682712
Some checks are pending
Publish Playground / build (push) Waiting to run
Publish Playground / deploy (push) Blocked by required conditions
Add list sugar
2026-03-29 19:54:01 -07:00

20 lines
232 B
Agda

module ListSugar
import Prelude
blah : List Int
blah = [ 1, 2, 3]
bar : List Int Int
bar [ ] = 0
bar [x] = 1
bar _ = 42
main : IO Unit
main = do
printLn blah
printLn $ bar []
printLn $ bar [ 42 ]
printLn $ bar blah