Hello monks, I have created some simple modules but it fails because it says I may need to install them first(maybe...I don't know?).

my question to you is,do I have to install them every time before even testing them?

it seems like alot of work before I even get to see them work correctly and,if not, debug and re-install can be a hassle

is there a way to circumvent that during testing ?

these are the code for your review, I will appreciate any criticism to improve format and readability. Looking for your advice in improving my scripts as always ;-)

package Dreamcar; sub modello{ my ($macchina, $modello) = @_; $modello && ($macchina->{'Modello'}=$modello); return $macchina->{'Modello'}; } 1;
package Scuderia; use Dreamcar; @ISA = qw[Dreamcar]; sub tipo{ my ($macchina, $tipo)=@_; if ($tipo){$macchina->{'Tipo'}=$tipo}; return $macchina_>{'Tipo'}; } 1;
package Da_corsa; use Scuderia;; @ISA= "Scuderia"; # we say that ISA e' macchina da corsa nella scuderi +a famosa #declaring a class of racing car sub class{ my($class)=@; my $macchina ={}; #empty anonomous hash bless $macchina, $class; return $macchina; } sub tempo_sul_giro { my ($macchina, $tempo)=@_; $tempo && ($macchina->{'Tempo_sul_Giro'}=$tempo); return $macchina->{'Tempo_sul_Giro'}; }
#testing the modules use strict; use warnings; use Data::Dump qw(dump); use Da_corsa; #inheritance adesso my $da_corsa = Da_corsa->class(); $da_corsa-> modello('Ferrari'); $da_corsa-> tipo('LaFerrari'); $da_corsa -> tempo_sul_giro('2.8 secondi'); print "the Racing car is from ", $da_corsa->modello()," and the type i +s ",$da_corsa->tipo(), " and can do 0-60MPH in : ", $da_corsa->tempo_dal_giro(),"\n";

In reply to PM module question/improvements by perlynewby

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.