fork(14) download
  1. using System;
  2. using System.Text.RegularExpressions;
  3.  
  4. public class Test
  5. {
  6. public static void Main()
  7. {
  8. string s = "+foo+ +---+ :bar: baz : : qux";
  9. s = Regex.Replace(s, @"\+-+\+|: +:", "");
  10. Console.WriteLine(s);
  11. }
  12. }
Success #stdin #stdout 0.05s 37240KB
stdin
Standard input is empty
stdout
+foo+  :bar: baz  qux