#!/usr/bin/perl -w # trigraph.pl - Don Yang (uguu.org) # # 07/07/07 use strict; sub CheckSubstr($$) { my ($line, $needle) = @_; if( index($line, $needle) >= 0 ) { print "Found $needle at line $.\n"; } } while(<>) { CheckSubstr($_, '??'); CheckSubstr($_, '<:'); CheckSubstr($_, ':>'); CheckSubstr($_, '<%'); CheckSubstr($_, '%>'); CheckSubstr($_, '%:'); CheckSubstr($_, '%:%:'); }