in reply to Handling large amounts of data in a perl script
There are some programming languages where you have to use object for more or less everything. Perl is not among them: in Perl you can use objects when they are useful, and other programming paradigms when they are more efficient. The calculation you want to do can be done in two or three lines of imperative programming code. This is less code lines than what you need just to set up an object. I would really not recommend objects for such simple calculations.
If you wish to learn OOP, be it with Perl or another language, fine, it is a great idea, but try to do it wit a more ambitious application. Or, put it in another way, the calculations and data munging you are contemplating is not the type of area where OOP is likely to give you any advantage over more conventional methods.
|
|---|