[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

*To*: info-dylan@cambridge.apple.com*Subject*: Working with generic functions*From*: Kenneth Knight <krk@oit.itd.umich.edu>*Date*: Wed, 2 Dec 92 13:58:28 EST

This is a bit of a change from the message that have been posted lately, but I can't seem to find the answer myself so here goes... I am writing methods to do some basic combinatorics (permutation, r-permutation , combinations, and so on). The problem is that I'd like to access the 'permute' function in two ways: 1. as P(n) for permuting an entire set of objects; and, 2. as P(n,r) for permuting n objects in r subsets. I have factorial written and it works. My problem is that from what I can tell (and what Thomas, thank Mark Feeley for a nice embedded version) I can not create two methods called 'permute' with different number of parameters. The param-lists are not congruent. I would very much like to call both of the functions 'permute' but I do not want the aggrivation of having to type (permute 6 6) to find out how many permutations are in a 6 objet set. Is there a way I can manage this? ** Ken **

- Prev by Date:
**Call for Authors** - Next by Date:
**Re: Working with generic functions** - Previous by thread:
**Call for Authors** - Next by thread:
**Re: Working with generic functions** - Index(es):