I have recently started studying Formal Language Theory and having some problems with finite and infinite languages.
I have been told that all finite languages are regular.
However, reading through the notes given to me, a grammar with productions:
S --> ab
S --> aabb
S --> aaabbb
Is not a regular language although the productions generate a finite number of strings.
However, a grammar with the productions:
S --> Sb
S --> Tb
T --> Ta
T --> a
Which generate strings of the form a^m b^n, which is an infinite list of strings yet this language is defined as regular?
Could anyone help me to understand in simple terms? Would be really appreciated as I am struggling.