<commit_before># primes

Fetch, locate and use prime numbers with this library. There's nothing more to
it than that.

## Usage

To use primes within your own Clojure programs and libraries, add this to
your `project.clj` dependencies:

```clj
[com.hypirion/primes "0.1.0"]
```

## License

Copyright © 2013 <NAME>

Distributed under the Eclipse Public License, the same as Clojure.
<commit_msg>Show example use and clarity thread-safety.<commit_after># primes

Fetch, locate and use prime numbers with this library. There's nothing more to
it than that.

The library is designed to rapidly generate primes by being a Clojure-wrapper on
top of a thread-safe Java class. You don't have to worry about anything, just
ride the wave and enjoy the view.

## Usage

To use primes within your own Clojure programs and libraries, add this to
your `project.clj` dependencies:

```clj
[com.hypirion/primes "0.1.0"]
```

From there, it's really easy to get working with primes:

```clj
(require '[com.hypirion.primes :as p])

(p/prime? 13)
#_=> true

(p/get 543210) ;; The 543210th prime, 0-indexed
#_=> 8054927

(p/take-below 100) ;; All primes below 100
#_=> #<UnmodifiableRandomAccessList [2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 
    37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97]>

(p/take 20) ;; The 20 first primes
#_=> #<UnmodifiableRandomAccessList [2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31,
    37, 41, 43, 47, 53, 59, 61, 67, 71]>

;; Lazy sequence of all primes ending with 1
(filter #(= 1 (mod % 10)) (p/primes))
#_=> (11 31 41 61 71 101 131 151 181 191 ...)
```

## License

Copyright © 2013 <NAME>

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

{'fraction_non_alphanumeric': 0.12283840190816935, 'fraction_numerical': 0.0936195587358378, 'mean_word_length': 3.979228486646884, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 12, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 7, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6214640', 'n_tokens_mistral': 750, 'n_tokens_neox': 570, 'n_words': 252}