#!/usr/bin/perl -w ####################################################### # class7_07_binding_op_subst # # ask for a filename, show what it would look like with # a different suffix if it ends in .pl # # modified by Sharon Tuttle from "Learning Perl", # by Schartz and Phoenix # # last modified: 5-2-03 ####################################################### print "enter a file name: "; chomp($file_name = ); # IF it ends in .pl, INSTEAD change the suffix to .plx $file_name =~ s/\.pl$/\.plx/; print "\$file_name is now: $file_name\n"; # end of class7_07_binding_op_subst