  The paper describes ergodic (with respect to the Haar measure) functions in
the class of all functions, which are defined on (and take values in) the ring
of p-adic integers, and which satisfy (at least, locally) Lipschitz condition
with coefficient 1. Equiprobable (in particular, measure-preserving) functions
of this class are described also. In some cases (and especially for p=2) the
descriptions are given by explicit formulae. Some of the results may be viewed
as descriptions of ergodic isometric dynamical systems on p-adic unit disk. The
study was motivated by the problem of pseudorandom number generation for
computer simulation and cryptography. From this view the paper describes
nonlinear congruential pseudorandom generators modulo M which produce stricly
periodic uniformly distributed sequences modulo M with maximal possible period
length (i.e., exactly M). Both the state change function and the output
function of these generators could be, e.g., meromorphic functions (in
particular, polynomials with rational, but not necessarily integer
coefficients, or rational functions), or compositions of arithmetical
operations (like addition, multiplication, exponentiation, raising to integer
powers, including negative ones) with standard computer operations, such as
bitwise logical operations (XOR, OR, AND, etc.). The linear complexity of the
produced sequences is also studied.
