fork(2) download
  1. using System;
  2. using System.IO;
  3. using System.Text.RegularExpressions;
  4.  
  5. public class Test
  6. {
  7. public static void Main()
  8. {
  9. Console.WriteLine(FindDispo_InInfo("12/11/2015: Liefertermin 71994 : 30.11.2015 -> 27.11.2015"));
  10. }
  11. private static string FindDispo_InInfo(string text)
  12. {
  13. Regex pattern = new Regex(@"\b[0-9]{5}\b");
  14. Match match = pattern.Match(text);
  15. if (match.Success)
  16. return match.Value;
  17. else
  18. return string.Empty;
  19. }
  20. }
Success #stdin #stdout 0.1s 24288KB
stdin
Standard input is empty
stdout
71994