~jojo/Carth

ref: 55fb4f948f1f3797078b584dc60b4f7dd68b37ed Carth/examples/count-lines.carth -rw-r--r-- 124 bytes
55fb4f94JoJo Check `cast` in Infer instead of Gen 5 months ago
                                                                                
1
2
3
4
5
;; Count lines of stdin

(import std)

(define main (io/bind display (io/map (<o show-nat (<o count lines)) get-contents)))