(println "hello, I'm a bot")
nil
"hello, I'm a bot\n"
(print "No, I'm human.")
nil
"No, I'm human."
(println "I hope I'm ok")
nil
"I hope I'm ok\n"
(println "Hai thar, I'm clojurebawt!")
nil
"Hai thar, I'm clojurebawt!\n"
(seq "or a string for that matter")
(\o \r \space \a \space \s \t \r \i \n \g \space \f \o \r \space \t \h \a \t \space \m \a \t \t \e \r)
(isa? String String)
true
(let [string "HELLO"] (= (.toUpperCase string) string))
true
(let [String 1] String)
1
(type String)
java.lang.Class
(let [string nil] (if string (.toLowerCase string) nil))
nil
(def fortune (atom "Help! I'm a slave worker trapped in a Chinese fortune cookie factory."))
#'user/fortune
(= '(String) [String])
false
(keyword "I am a string with spaces")
:I
(isa? String (new String "a"))
false
(let [String 1] (println String))
nil
"1\n"
(print "Hi, I'm clojurebot. This sentence is false.")
nil
"Hi, I'm clojurebot. This sentence is false."
(isa? [String String] [Object Object])
true
(merge {String 0} {String 1})
{java.lang.String 1}
(let [string "foo"] (.hashCode #^java.lang.String string))
101574
(defn encode-in-utf-8 [string] (.getBytes string "UTF-8"))
#'user/encode-in-utf-8
(instance? String "foo")
true
(def string "foo")
#'user/string
(isa? String Object)
true
(derive String ::Foo)
nil
(identity String)
java.lang.String
(parents String)
#{java.io.Serializable java.lang.CharSequence java.lang.Comparable java.lang.Object java.lang.constant.Constable java.lang.constant.ConstantDesc}
(class String)
java.lang.Class
(defrecord String [])
#'user/String
(class? String)
true
(ancestors String)
#{java.io.Serializable java.lang.CharSequence java.lang.Comparable java.lang.Object java.lang.constant.Constable java.lang.constant.ConstantDesc}
(var String)
java.lang.String
(defn capitalize [string] (apply str (.toUpperCase (str (first string))) (rest string)))
#'user/capitalize
(= (into-array String ["la" "clojure"]) (into-array String ["la" "clojure"]))
false
(let [string "foo"] (.hashCode #^String string))
101574
(defn printer [stream string] (.write stream string))
#'user/printer
(supers String)
#{java.io.Serializable java.lang.CharSequence java.lang.Comparable java.lang.Object java.lang.constant.Constable java.lang.constant.ConstantDesc}
(.new String)
""
(new String)
""
(print String)
nil
"java.lang.String"
(defn a [y] (case (class y) Integer "int" String "stringy"))
#'user/a
(identical? String (class "hello"))
true
(meta (with-meta [] {:tag String}))
{:tag java.lang.String}
(defn split [string delim] (seq (.split string delim)))
#'user/split
(defn split [string delim] (seq (.split string delim)))
#'user/split
(instance? String "abc")
true
(isa? String "hi")
false
(instance? String 42)
false
(new String "foo")
"foo"
(new String "a")
"a"
(isa? String "foo")
false