  In this paper we investigate the connection between the Mac Lane (co)homology
and Wieferich primes in finite localizations of global number rings. Following
the ideas of Polishchuk-Positselski \cite{PP}, we define the Mac Lane
(co)homology of the second kind of an associative ring with a central element.
We compute this invariants for finite localizations of global number rings with
an element $w$ and obtain that the result is closely related with the Wieferich
primes to the base $w.$ In particular, for a given non-zero integer $w,$ the
infiniteness of Wieferich primes to the base $w$ turns out to be equivalent to
the following: for any positive integer $n,$ we have
$HML^{II,0}(\mathbb{Z}[\frac1{n!}],w)\ne\mathbb{Q}.$
  As an application of our technique, we identify the ring structure on the Mac
Lane cohomology of a global number ring and compute the Adams operations
(introduced in this case by McCarthy \cite{McC}) on its Mac Lane homology.
