Abh*_*kar 17
确实存在:
Clojure 1.2.0
user=> (not= 1 2)
true
user=> (not= 1 1)
false
Run Code Online (Sandbox Code Playgroud)
Ray*_*yne 16
user=> (doc not=)
-------------------------
clojure.core/not=
([x] [x y] [x y & more])
Same as (not (= obj1 obj2))
nil
Run Code Online (Sandbox Code Playgroud)
有趣的是,如果你真的想要,你可以定义!=与not =相同:
user=> (def != not=)
#'user/!=
user=> (!= 2 2)
false
user=> (!= 2 3)
true
Run Code Online (Sandbox Code Playgroud)
在很多clojure代码中!char表示函数以您应注意的方式更改某些事物的状态.在Clojure的瞬变大量使用这些
compare-and-set!
alter-meta!
conj!
persistent!
Run Code Online (Sandbox Code Playgroud)
查看http://clojure.github.com/clojure/并搜索!字符.这些功能通常带有"必须没有副作用"的警告
| 归档时间: |
|
| 查看次数: |
486 次 |
| 最近记录: |