Finite automata and numbers