I came across the following statement which is supposedly true:
There exists an infinite set of regular languages, such that their union is not a CFL
it is explained this way: we'll define $L_k = \{ 0^k1^k0^k \}$
$\bigcup_{i=1}^{\infty} $ $ L_i = \left\{ 0^k1^k0^k \mid k \geq 1 \right\} $
so that each language in the union only contains one string and therefore - regular, but their union is equivalent to: $0^n1^n0^n$ which is not CF.
on the other hand regular languages are closed under union, which means it'd be easy to prove inductively that the above union = regular language, since it consists only of regular languages.
and all regular languages are CF.
isn't that a contradiction?