We study the number of $0,1$-words where the fraction of 0 is "almost" fixed
for any initial subword. It turns out that this study use and reveal the
structure of the Galois group (the monodromy group) of the polynomials
$(x+1)^n-\lambda x^p$. ($p$ is not necessary a prime here.)
Almost-commuting matrices with respect to the normalized Hilbert-Schmidt norm
are considered. Normal almost commuting matrices are proved to be near
commuting.
Given a prime $p$, we consider the dynamical system generated by repeated
exponentiations modulo $p$, that is, by the map $u \mapsto f_g(u)$, where
$f_g(u) \equiv g^u \pmod p$ and $0 \le f_g(u) \le p-1$. This map is in
particular used in a number of constructions of cryptographically secure
pseudorandom generators. We obtain nontrivial upper bounds on the number of
fixed points and short cycles in the above dynamical system.