counting the amount of occurances when splitting a string c#

hello i have a script that needs to split a string “1,2,3,4,5,6,7” into an array using the comma as a delimiter but it also need to count the amount of times it delimits if that makes sense.

this is the lua equivalent that i had on hand it uses gsub to split the string using commas and counts the amount of times

local _,n = string.gsub(inputString,"(%w+)",function(s) table.insert(t,s) end)

string[ ] things = thestring.Split(“,”[0]); edit: “,”[0] is the delimiter (char)
int thingCount = things.Length;