Subject: Routine to derive combinations of r objects chosen from among n

From: Alex May <[email-masked]>
Date: Wed, 18 Oct 1995 20:20:28 +0100 (BST)

Hi all,

		Thought that it was time that I moved from the shadows and 
actually asked a question. Here goes:

	I'm looking for an algorithm which derives combinations of r objects 
chosen from among n. For instance, with 3 objects A,B and C there are 3 
combinations of pairs: AB,AC and BC. It seems to be a natural candidate 
for recursion a la factorial... 

	I don't want to reinvent the wheel (who does? ;-)) so does anybody have
any suggestions? Incidentally, I don't have access to all 7 volumes of 
Knuth's "The art of computer programming". 

	Anyhow, I'll go back to being a lurker now...

	Thanks a lot.

				Alex

Alex May
Department of Crystallography, Birkbeck College, Malet Street, London WC1E 7HX.
Tel. 0171- 631 6842 (Direct line) Fax  0171- 631 6805
[email-masked]