This function loops over each character of the string provided as its
first argument, evaluating the code given as its third argument for
each character substituting it for the %-substitution given as the
second argument.

@strloop("hello world", "x", @switch("%x", "l", @print("Boo!"))
  (Prints 'Boo!' three times, because there are three l's in 'hello world'.)
@strlen(@strloop("The quick red fox jumped...", "letter", @switch(@lc("%{letter}"), "e", ".", "")))
   (Count e's.)