Splitting a string into an array of substrings is a common operation in C# programming, allowing you to parse and…