將字符串轉(zhuǎn)換為所有小寫。
以下是lower-case的基本使用語法:
(lower-case s)
參數(shù) ? where's'是要轉(zhuǎn)換的字符串。
返回值 ? 小寫字符串。
下面是lower-case函數(shù)的示例:
(ns clojure.examples.hello (:gen-class)) (defn hello-world [] (println (clojure.string/lower-case "HelloWorld")) (println (clojure.string/lower-case "HELLOWORLD"))) (hello-world)
以上示例將輸出以下結(jié)果:
helloworld helloworld
更多建議: