Calculate the N-th combination of a string given a starting string and possible chars.