Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public static object SplitStr(string input, int id, char c = ' ')
- {
- string output = "";
- string[] words = input.Split(new char[] { c });
- int i = 0;
- foreach (string s in words) {
- if (i == id) {
- output = s;
- }
- i += 1;
- }
- return output;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement