Thank you both - I was simply copying my last PRINT statement at the end of the script when I was adding the IF/ELSE statement.
But now I've run into a new problem - I ran the script after making that simple change and it stopped at record 140, which is the first "error" record in the file (line 4 of my sample code in my original post) and is giving me this message, then stopping -
Can't use string ("650187016") as an ARRAY ref while "strict refs" in use at AlterData.pl line 39, <$FH> line 140.