Rubrikk Group interview question

Solving hypothetical programming algorithm for parsing string input