Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Re: Design elegance : How to best design this simple program ?

by cavac (Parson)
on Jun 18, 2012 at 20:08 UTC ( [id://976888]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    piggybank/brother.csv
    piggybank/sister.csv
    piggybank/mother.csv
    piggybank/test.csv
    
  2. or download this
    deposit;1
    beer;-30
    beer;-20
    won bet;200
    
  3. or download this
    deposit;1000
    buy coffee;-20
    buy lunch;-30
    new shoes;-500
    deposit;20
    
  4. or download this
    deposit;50
    deposit;30
    deposit;300
    small car accident;-550
    
  5. or download this
    #!/usr/bin/env perl
    use strict;
    ...
        
        print "Found data file $fname\n";
    }
    
  6. or download this
    #!/usr/bin/env perl
    use strict;
    ...
        }
        close $fh;
    }
    
  7. or download this
    sometext;value
    
  8. or download this
    sub readAccount {
        my ($fname) = @_;
    ...
        close $fh;
        print "$fname balance: $balance\n";
    }
    
  9. or download this
    #!/usr/bin/env perl
    use strict;
    ...
        print "$fname balance: $balance\n";
        return $balance;
    }
    
  10. or download this
    piggybank/brother.csv balance: 151
    piggybank/test.csv is not a file!
    piggybank/mother.csv balance: -170
    piggybank/sister.csv balance: 470
    Money left in the piggybank: 451
    

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://976888]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others rifling through the Monastery: (5)
As of 2024-03-28 22:24 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found