ClojureDocs

导航

命名空间

cond

clojure.core

自 1.0 起可用 (源代码)
  • (cond & 子句)
Takes a set of test/expr pairs. It evaluates each test one at a
time.  If a test returns logical true, cond evaluates and returns
the value of the corresponding expr and doesn't evaluate any of the
other tests or exprs. (cond) returns nil.