They’re not the same when the second argument is negative:

```
2 `mod` (-3) == -1
2 `rem` (-3) == 2
```

### Related Contents:

- Getting started with Haskell
- What is Haskell used for in the real world? [closed]
- Why do we need monads?
- Good Haskell source to read and learn from [closed]
- Why are side-effects modeled as monads in Haskell?
- What is “lifting” in Haskell?
- Why is GHC so large/big?
- Haskell: Where vs. Let
- Why is lazy evaluation useful?
- Memory footprint of Haskell data types
- What’s the point of map in Haskell, when there is fmap?
- Why does Haskell’s “do nothing” function, id, consume tons of memory?
- What’s the absurd function in Data.Void useful for?
- What’s the point of ‘const’ in the Haskell Prelude?
- Haskell: why the convention to name a helper function “go”?
- Haskell offline documentation?
- How does this piece of obfuscated Haskell code work?
- How does foldr work?
- Why can I not make String an instance of a typeclass?
- Haskell “do nothing” IO, or if without else
- Orphaned instances in Haskell
- Concrete example showing that monads are not closed under composition (with proof)?
- What is the combinatory logic equivalent of intuitionistic type theory?
- Why should I use applicative functors in functional programming?
- What is a monad?
- What is the DataKinds extension of Haskell?
- Haskell – foldl and foldr?
- How to properly communicate compile-time information to Template Haskell functions?
- Difference between Monad and Applicative in Haskell
- What does $ mean/do in Haskell?
- Which Haskell (GHC) extensions should users use/avoid? [closed]
- Data Constructor promotion in GHC-7.6
- Is there a better way to have optional function arguments in Haskell?
- Understanding Arrows in Haskell
- What does ‘qualified’ mean in ‘import qualified Data.List’ statement?
- How do I write, “if typeclass a, then a is also an instance of b by this definition.”
- Mixing Erlang and Haskell
- Binding FFI and DSL
- ghci configuration file
- Avoiding lift with monad transformers
- Web Scraping With Haskell
- Curious about the HashTable performance issues
- Simple examples to illustrate Category, Monoid and Monad?
- Is there a Haskell idiom for updating a nested data structure?
- ST Monad == code smell?
- Should I use a lexer when using a parser combinator library like Parsec?
- How does Haskell tail recursion work?
- Independent subset of cabal packages set
- Haskell ranges and floats
- Is Haskell really a purely functional language considering unsafePerformIO?