+1 I use sets prodigiously, and I also require such functions. -Ian ----- Original Message ----- From: "David Van Horn" <dvanh...@ccs.neu.edu> To: users@racket-lang.org Sent: Thursday, September 8, 2011 8:12:18 PM GMT -05:00 US/Canada Eastern Subject: Re: [racket] Take an element from a set
On 9/7/11 11:36 PM, Shriram Krishnamurthi wrote: > A better design would be to use a different signature: > > get-one/rest : (forall (A) (Set A) -> (values A (Set A))) > > This performs the split "atomically", so it can ensure that the > combination of "one" and "rest" is the same as the original set. This should be provided by Racket. I've written it locally multiple times. David _________________________________________________ For list-related administrative tasks: http://lists.racket-lang.org/listinfo/users _________________________________________________ For list-related administrative tasks: http://lists.racket-lang.org/listinfo/users