Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
11
Task/Regular-expressions/Racket/regular-expressions.rkt
Normal file
11
Task/Regular-expressions/Racket/regular-expressions.rkt
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
#lang racket
|
||||
|
||||
(define s "I am a string")
|
||||
|
||||
(when (regexp-match? #rx"string$" s)
|
||||
(displayln "Ends with 'string'."))
|
||||
|
||||
(unless (regexp-match? #rx"^You" s)
|
||||
(displayln "Does not start with 'You'."))
|
||||
|
||||
(displayln (regexp-replace " a " s " another "))
|
||||
Loading…
Add table
Add a link
Reference in a new issue