home *** CD-ROM | disk | FTP | other *** search
/ ftp.cse.unsw.edu.au / 2014.06.ftp.cse.unsw.edu.au.tar / ftp.cse.unsw.edu.au / pub / doc / languages / perl / nutshell / ch2 / dehyph < prev    next >
Encoding:
Text File  |  1992-10-18  |  241 b   |  9 lines

  1. #!/usr/bin/perl
  2.  
  3. $/ = "";                        # Enable paragraph mode.
  4. $* = 1;                         # Enable multi-line patterns.
  5. while (<>) {
  6.     s/-\n//g;                  # Dehyphenate hyphenations.
  7.     print if /\bprosperous\b/;
  8. }
  9.