import-bot (20211) [Avatar] Offline
Re: pg. 28 example code - curly brackets
[Originally posted by leegold]

I see, it'd help if I used curly brackets in the sub.
I think { vs. ( is a little hard to tell w/some fonts.
Works fine now.
import-bot (20211) [Avatar] Offline
[Originally posted by leegold]

If anyone could help. Thanks.
When I run tax_calc I get the error message:

Undefined subroutine &main::get_price_input called at line 19.

And here's what i typed, line 19 to the prog. end:

$price = get_price_input();
$sales_tax = int ( $sales_tax_rate * $price );
$total_price = ($price + $sales_tax ) / 100;

print "Total price is $total_price

sub get_price_input (
return 1015; # dummy function for example only