Help for this page

Select Code to Download


  1. or download this
    sub euroCalc
    {
    ...
        # Or in one line
        return ($amount * $rates{$to}) / $rates{$from};
    }
    
  2. or download this
    use strict;
    use Calc::Euro;
    ...
    print $eurocalc->euroCalc(1,'NLG','BEF'), "\n"; 
    print $eurocalc->euroCalc(1,'NLG','EUR'), "\n";
    print $eurocalc->euroCalc(1,'EUR','NLG'), "\n";