Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
SpiltStringBetweenSpecialCharacters
//Rextester.Program.Main is the entry point for your code. Don't change it. //Compiler version 4.0.30319.17929 for Microsoft (R) .NET Framework 4.5 using System; using System.Collections.Generic; using System.Linq; using System.Text.RegularExpressions; namespace Rextester { public class Program { public static void Main(string[] args) { string tempaddress = "303!<>!|!<>!203"; char[] c = tempaddress.ToCharArray(); string First=""; for(int i=0;i<c.Length;i++) { if(Char.IsLetterOrDigit(c[i])) { First = First + c[i]; } else { break; } } Console.WriteLine(First); string address = Regex.Replace(tempaddress, @"[^0-9a-zA-Z]+", ""); Console.WriteLine(address); Console.WriteLine(address.Replace(First,"")); } } }
run
|
edit
|
history
|
help
0
Convert String to Pig Latin
Plt-D v.0.8.5
Palindrome
Side 1
up casting down casting
ruSrib
opQ 3
Static 2
30272 Program Ex3
SKR2