Name

about:regular-expressions

Description

Standard regular expression

user > #/aap/
it: #/aap/
user > :d
#s( :members #s( :match-timeout -00:00:00.0010000
                 :options None
                 :right-to-left false )
    :type "Kiezel.RegexPlus"
    :value #/aap/ )

user > (.regex-match "slaap" #/aap/)
it: ("aap")
user > #/(a*)(p)/i
it: #/(a*)(p)/i
user > :d
#s( :members #s( :match-timeout -00:00:00.0010000
                 :options IgnoreCase
                 :right-to-left false )
    :type "Kiezel.RegexPlus"
    :value #/(a*)(p)/i )

user > (.regex-match "SLAAp" #/(a*)(p)/i)
it: ("AAp" "AA" "p")

Regular expression from a wildcard pattern

user > #/*.k/w
it: #/^(.*?)\.k$/
user > (filter #/*.k/w '("a.k" "b.cs" "c.K"))
it: ("a.k")
user > (filter #/*.k/wi '("a.k" "b.cs" "c.K"))
it: ("a.k" "c.K")

Regular expression as a function

user > (filter #/aap/ '("slaap" "jaap" "teun" "mies" "jaap"))
it: ("slaap" "jaap" "jaap")