To compare, get_data_count() and print_data_count(), I first use perltidy to eliminate variation due to different ways of formatting Perl code.
I then use the Unix utility diff to compare the two subroutines.
The small number of different lines indicates that much of the code is repeated.
    3c3
    < sub get_data_count {
    ---
    > sub print_data_count {
    12c12
    <     return $count;
    ---
    >     print "Current data count:  $count\n";
I smell a subroutine!
| Previous | Back to start of show | Next | 
| Slide: 12 diff | © 2003 James E. Keenan |