Skip to content

Instantly share code, notes, and snippets.

@xrrocha
Last active December 16, 2020 18:12
Show Gist options
  • Save xrrocha/a24a180549fa5a5dafa2da66085ec9d4 to your computer and use it in GitHub Desktop.
Save xrrocha/a24a180549fa5a5dafa2da66085ec9d4 to your computer and use it in GitHub Desktop.
code block for README-15
// Examine text looking for matches
WORD_REGEX.matcher(text).results()
.forEach(match -> {
// Second letter
final var start = match.start() + 1;
// Penultimate letter
final var end = match.end() - 1;
final var length = end - start;
// ... shuffling stuff ...
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment