JanetDocsPlaygroundI'm feeling luckyGitHub sign in

any?



    function
    boot.janet on line 1289, column 1

    (any? ind)

    Returns the first truthy value in ind, otherwise nil. falsey value.


See also:allsome2 examplesSign in to add an example
Loading...
(any? "")
# => nil

(any? "Hello")
# => 72

(any? @"Hello")
# => 72

(any? @[])
# => nil

(any? [])
# => nil

(any? {})
# => nil

(any? @{})
# => nil

(any? @[1 2 3 4])
# => 1 

(any? @{:a 2 :b 3})
# => 2
leobmPlayground
(any? [false false nil]) => nil
(any? [false false nil 1]) => 1
(any? [false false nil true]) => true
swlkrPlayground