in reply to
Where to put self-made loop logic (separate module)?
Good questions - all of which have extensive documentation easily available. You can start at perlootut.
If you post your code here, we could help you with the OO encapsulation, or suggest alternatives.
Don't be afraid to post early, or semi working code, and request help - everyone learns form that activity, and we are quite happy to do that.
"By three methods we may learn wisdom: First, by reflection, which is noblest; Second, by imitation, which is easiest; and third by experience, which is the bitterest."