Limiting pulses/impulses

Hello everybody

I've started programming arduino a few months ago and im just starting, and i want to do something...but im stuck, and i dont know if it is possible or not.

What i want to know if it is possibe to limit pulses, so having an input and an output, where for example i get 5 pulses per second in the input pin then limiting and getting 4 or 3 pulses per second at the ouput pin.

Ive seen seen the PulseIn() commando but im not sure if i can do it with this commando.
And my last question is if I can limit it by a commando so it stays on one position or if i can modify the limit, so change from 3 to 4 pulses or viceversa with a potentiometer or something similar.

Thank already