fork download
  1. using System;
  2. using System.Collections;
  3. using System.Collections.Generic;
  4. using System.Text.RegularExpressions;
  5.  
  6. public class Test
  7. {
  8. public static void Main()
  9. {
  10. var text = "aaa<p>AI.For example <p>A.I<p>BB.b";
  11. text = Regex.Replace(text, @"(?=<p>\s*([A-Z])\1*\.)", "\uFFFF");
  12. var result = text.Split('\uFFFF');
  13. Console.WriteLine(string.Join("\n", result));
  14. }
  15. }
Success #stdin #stdout 0.06s 20804KB
stdin
Standard input is empty
stdout
aaa<p>AI.For example 
<p>A.I
<p>BB.b