Fellow Monks,
Consider my next question a very basic question, purely for my own fun:
What is better or more preferred in the next example (and why?):
A)
my $T;
if ($hour > 12) {
$hour -= 12;
$T = 'PM';
} else {
$T = 'AM';
}
See the detail?
I was wandering what 'solution' would be better, since I run into these kind of thing regularly and it made me curious if there would be a 'common' way to handle this.
Rgds,
John