well, I would start by reading each character from left to right and checking it against the ascii of 0-9. Once you get your first "number" set a bool to true, then while next character is 0-9, cont, stop when false thus eliminating the " . " And while true, keep concatinating the next numb to the prev set