【发布时间】:2015-02-26 19:43:03
【问题描述】:
从这个 SO 问题:List Comprehension in Ocaml?,我可以使用opam install pa_comprehension 安装理解包,并在顶级 REPL 中使用该包。
# #require "pa_comprehension";;
# open Batteries;;
# [? 2 * x | x <- 0 -- max_int ; x * x > 3 ?];;
- : int Batteries.Enum.t = <abstr>
那么,我该如何编译代码呢?
【问题讨论】:
标签: ocaml list-comprehension ocaml-batteries