Facebook
From Scott, 1 Month ago, written in Perl.
This paste is a reply to Untitled from Scott - view diff
Embed
Download Paste or View Raw
Hits: 163
  1. # Find the *first* three letter word in the string
  2. my $str = "one two three four five six seven eight nine ten";
  3. my @x   = $str =~ m/b(w{3})b/; # ("one")