Erlang implementation of Quantifoocation