Note that this is a bit of a tricky problem. Normally if you have some arbitrary constraint given by a predicate $P$ over the variables:
$$L = \{1^a2^b3^c | P(a, b, c) \}$$
this won't be regular in that general case. How can a language like this with a constraint given mathematically be regular?
But $(a + b + c) | 2$ is an interesting special case.
To determine whether the sum of three numbers is odd or even, we just have to look at the last binary digit. When we add binary numbers together, the least significant digit is a simple boolean function of the operands: the xor
function.
So, intuitively, we suspect that the recognizer for the language we are working does not have to be able to count or memorize anything, which points to regularity.
$a + b$ is even precisely when both $a$ and $b$ are even, or when they are both odd. $a + b + c$ is even if and only if all three variables are even, or if exactly one of them is even (any two out of the three are odd).
So, this gives us four cases:
(11)*(22)*(33)* # regex for even number of 1's, 2's and 3's:
1(11)*2(22)*(33)* # regex for odd number of 1's, odd number of 2's, even 3's:
1(11)*(22)*3(33)* # two more cases:
(11)*2(22)*3(33)*
Now these are just combined with the branch | operator into a single regex:
(11)*(22)*(33)*|1(11)*2(22)*(33)*|1(11)*(22)*3(33)*|(11)*2(22)*3(33)*
This can probably be simplified, but it is not necessary to do so.
By the equivalence of regexes, finite automata, and regular languages, quod erat demonstrandum.