Ad hoc, frequency counting