There's also this obfuscated
let f='.';o c(x:y)=x:c y;z c(x:y)=f:c y;p n='p':ap fix p(o.n)in f:f:p z
defining the `bitmap' of prime numbers ..pp.p.p...p.p...p.p...p.....p.p.....p...p.p...p.. ...
while avoiding arithmetic altogether.
https://wiki.haskell.org/Prime_numbers
And a long list of algorithms. Many of which are surprising and probably not that efficient. The first few are:
https://wiki.haskell.org/Prime_numbers_miscellaneous#Prime_W...
Efficiency is kind of a relative issue, since you don't know the job beforehand or which one would be optimal