Taken from wikipedia:
"Angulimala was sent to Taxila to study under a well-known Brahmin
guru. There he excelled in his studies and became the teachers'
favourite student, enjoying special privileges in his teachers'
house. However, the other students grew jealous of Ahimsaka's
speedy progress and sought to turn his master against him. To that
end, they made it seem as though Ahimsaka had seduced the master's
wife and boasted that he was wiser than the guru. Unwilling or
unable to attack Ahimsaka directly (Pad states that Ahimsaka was as
"strong as seven elephants", while Ps states that the teacher
worried that his business would suffer if he was found to have
murdered a student (!)), the teacher said that Ahimsaka's training
was complete, but that he must provide the traditional final gift
offered to a guru before the teacher would grant his approval. As
his payment, the teacher demanded 1,000 fingers, each taken from a
different victim, thinking that Angulimala would be killed in the
course of seeking this grisly prize (Pad states that Angulimala was
required to fetch 1,000 fingers from right hands, seemingly unaware
that this could be achieved by killing 200 people. Ps states, even
more strangely, that he was told to "kill a thousand legs", and
gathered fingers only as an aid to keeping an accurate
count)."
Theorectically, he is supposed to attain the Dharma by the last
finger. Of course, all souls of the people he killed will attain
the Dharma too...