cats #539(2007/07/11 07:32 GMT) [ C# ] Rating0/0=0.00
1 2 3 4 5 6 7 8 9 10 11 12 13
using System; using System.Text; using System.Text.RegularExpressions; class Program { static void Main(string[] args) { string[] ss = {"AAA", "AAA/*/BBB", "AAA/*BBB", "AAA/*BBB*/CCC", "AAA/*BBB/*CCC*/DDD*/EEE", "AAA/a//*BB*B**/CCC"}; foreach (string s in ss) Console.WriteLine(Regex.Replace(Regex.Replace(s, "\\/\\*.*?\\*\\/", ""), "\\/\\*.*$", "")); } }
Rating0/0=0.00-0+
[ reply ]
cats #539() [ C# ] Rating0/0=0.00
Rating0/0=0.00-0+
[ reply ]