  We propose a new explanation for the origin of angular momentum in galaxies
and their dark halos, in which the halos obtain their spin through the
cumulative acquisition of angular momentum from satellite accretion. In our
model, the build-up of angular momentum is a random walk process associated
with the mass assembly history of the halo's major progenitor. We assume no
correlation between the angular momenta of accreted objects. Using the extended
Press-Schechter approximation, we calculate the growth of mass, angular
momentum, and spin parameter $\lambda$ for many halos. Our random walk model
reproduces the key features of the angular momentum of halos found in N-body
simulations: a lognormal distribution in $\lambda$ with an average of
$<\lambda> \approx 0.04$, independent of mass and redshift. The evolution of
the spin parameter in individual halos in this model is quite different from
the steady increase with time of angular momentum in the tidal torque picture.
We find both in N-body simulations and in our random walk model that the value
of $\lambda$ changes significantly with time for a halo's major progenitor. It
typically has a sharp increase due to major mergers, and a steady decline
during periods of gradual accretion of small satellites. The model predicts
that on average the $\lambda$ of halos which had major mergers after redshift
$z=2$ should be substantially larger than the $\lambda$ of those which did not.
Perhaps surprisingly, this suggests that halos that host late-forming
elliptical galaxies should rotate faster than halos of spiral galaxies.
