Pregunta de entrevista de Roblox

A searching/counting problem, and a string manipulation/parsing problem.