Parse chemical formula with multipliers | TikTok Interview Question