Skip to content

Latest commit

 

History

History
19 lines (13 loc) · 292 Bytes

Regular_expressions.md

File metadata and controls

19 lines (13 loc) · 292 Bytes
if 'a long string' ~~ /string$/ {
   say "It ends with 'string'";
}

# substitution has a few nifty features

$_ = 'The quick Brown fox';
s:g:samecase/\w+/xxx/;
.say;
# output:
# Xxx xxx Xxx xxx