We all know that (a + b)*
is a regular language for containing only symbols a
and b
.
But (a + b)*
is a string of infinit
Each word in the language (a+b)
is of finite length. The same way as there are infinitely many integers, but each of them finite.
Yes, the language itself is an infinite set. Most languages are. But a finite automaton (NB: automata is plural) works just fine for them, provided each word is of finite length.
As an aside: This type of question probably should go to cs.stackexchange.com.