Advertisement
Guest User

Untitled

a guest
Oct 27th, 2016
58
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.59 KB | None | 0 0
  1. if (startIndex == word.Length)
  2. {
  3. result.Add(new string(word));
  4. return;
  5. }
  6. if (char.IsLetter(word[startIndex]))
  7. {
  8. AlternateCharCases(word.ToArray(), startIndex + 1, result);
  9. word[startIndex] = Char.ToUpper(word[startIndex]);
  10. AlternateCharCases(word.ToArray(), startIndex + 1, result);
  11. }
  12. else
  13. {
  14. AlternateCharCases(word, startIndex + 1, result);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement