Sum of multiples of 3 or 5 below N
Specification

There is  some possible ambiguity in the specification: Are multiples of 15 counted once as in FizzBuzz or twice as in a more mathematical specification?

Mathematics

The general problem of summing a sequence of integers is well understood



The pseudo code for the FizzBuzz version of the problem:

   threes   = (n/3).toInteger
   fives    = (n/5).toInteger
   fifteens = (n/15).toInteger

   sigmaThrees = [threes * (threes + 1) / 2] * 3
   sigmaFives = ...
   sigmaFifteens = ...

   return sigmaThrees + sigmaFives - sigmaFifteens


Implementation

The implementation should use Haskell's quot to perform integer division.

Performance

Blazingly fast. Not just because there are few calculations but also quot usually runs as a hardware integer operation.