my %products; $products{"Product1"}{"price"}=100; $products{"Product1"}{"description"}="A worthless widget"; foreach my $product (keys %products) { if ($product == $whatevertheuserselected) { # do something cool here $total =+ $products{$product}{"price"}; $email_body .= $products{$product}{"description"}; } }
In reply to Re: Coding for maintainability
by xorl
in thread Coding for maintainability
by monsterzero
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |