Hi I am programming in clojure and though the problem of modulo inverse has
nothing to do with language i am stuck at this code -
(defn EulerDiv [x p]
(let [ToMod (+ p 2)]
(loop [num 1 toPow (int p) numDouble x]
(if (= 0 toPow)
num
(let [numDouble2 (rem
exponent notation.
hth
lvh
On 13 Oct 2014, at 10:20, Ashish Negi thisismyidash...@gmail.com wrote:
Hi I am programming in clojure and though the problem of modulo inverse has
nothing to do with language i am stuck at this code -
(defn EulerDiv [x p]
(let [ToMod (+ p 2
of modulo inverse
has nothing to do with language i am stuck at this code -
(defn EulerDiv [x p]
(let [ToMod (+ p 2)]
(loop [num 1 toPow (int p) numDouble x]
(if (= 0 toPow)
num
(let [numDouble2 (rem (* numDouble numDouble
On Monday, October 13, 2014 4:34:16 AM UTC-4, Laurens Van Houtven wrote:
Hi Ashish,
At first sight, this looks like a numerical precision problem. 1e80 is a
floating point type, not an integer type. You may want to try with e.g.
1000N (note the N; that makes it a bigint). I
just lost in the shuffle of holiday time?
On Mon, Dec 22, 2008 at 4:04 AM, Mark Engelberg
mark.engelb...@gmail.com wrote:
Anyone know why there is no modulo or mod function in Clojure's core?
I know there is a rem function, but that's not the same thing. mod
and rem behave
, no one else cares about this, or was the post
just lost in the shuffle of holiday time?
On Mon, Dec 22, 2008 at 4:04 AM, Mark Engelberg
mark.engelb...@gmail.com wrote:
Anyone know why there is no modulo or mod function in Clojure's core?
I know there is a rem function, but that's
I suppose then that we would also need div. Using GHCi here:
Prelude (-3) `div` 2
-2
Prelude (-3) `quot` 2
-1
On Dec 22, 7:04 am, Mark Engelberg mark.engelb...@gmail.com wrote:
Anyone know why there is no modulo or mod function in Clojure's core?
I know there is a rem function, but that's