Basic HTML version of Foils prepared March 30 97

Foil 68 Filled Fields (Chapter 11 of Llama Book)

From PERL4 Tutorial for CPS616 Computational Science for Information Age Course CPS616 -- February 1995. by Geoffrey C. Fox


1 A filled field is designed for text which is to be broken at word boundaries but could be of arbitrary length. Here such text is specified by initial carat:
  • ^<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
  • $text
  • ^<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
  • $text
  • ^<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
  • $text
  • .
  • where number of <'s plus one is maximum size of field on each line
2 Note how one can repeat input variable so that Perl will process $text in above example over three input lines. Characters output on one line are discarded and remaining part (of $text) passed to next line
3 The special ~~ construct
4 ~~ ^<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
5 $text
6 .
7 will repeat pictureline following ~~ until associated variable (here $text) is exhausted

in Table To:


© Northeast Parallel Architectures Center, Syracuse University, npac@npac.syr.edu

If you have any comments about this server, send e-mail to webmaster@npac.syr.edu.

Page produced by wwwfoil on Sat Sep 6 1997