title: expands shorthand notations like 1-3 in the string to array of strings in C
body: <p>Lets say I have a string XYZ1-3.</p>
  
  <p>I would like to convert it to a array of strings.
  XYZ1,
  XYZ2,
  XYZ3.</p>
  
  <p>is there an elegant way to do it in C?</p>