Skip to content

bodil/unpredictable

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Unpredictable

Unpredictable is a collection of Clojure functions for producing randomness.

Usage

Add the dependency to your project.clj:

[unpredictable "0.1.0"]

Now use it like this:

;; Make a set of 5 distinct items from the sequence
> (rand-from-seq 5 (range 10))
#{1 2 3 6 7}

;; Map 3 random items from the sequence through str
> (rand-map 3 str (range 10))
(0 1 2 "3" "4" 5 6 7 "8" 9)

License

Copyright © 2012 Bodil Stokke

Distributed under the Eclipse Public License, the same as Clojure.

About

More randomness for Clojure

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published