Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- auto re = [r"[^`]`([^`]+)", "```"];
- bool inCode;
- foreach (m; text.matchAll(re))
- {
- if (m[0] == "```")
- {
- inCode = !inCode;
- }
- if (!inCode) {
- writeln(">>>");
- writeln(m[1]);
- writeln("<<<");
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement