Answers for "split string from int c#"

C#
1

c# string split by length

static IEnumerable<string> Split(string str, int chunkSize)
{
    return Enumerable.Range(0, str.Length / chunkSize)
        .Select(i => str.Substring(i * chunkSize, chunkSize));
}
Posted by: Guest on November-24-2021
0

c# split string

var lines = input
  .ReplaceLineEndings()
  .Split(Environment.NewLine, StringSplitOptions.None);
Posted by: Guest on March-31-2022

C# Answers by Framework

Browse Popular Code Answers by Language