Basic HTML version of Foils prepared March 30 97

Foil 17 Arrays and Lists of Scalars(data) II -- Construction (Chapter 3 of Llama Book)

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


1 There is a list construction operator .. which provides a list by values incremented by 1
  • @fred = (1..4); # is list (1,2,3,4) and
  • @fred = (2,3, $a..$b); # is a list determined by CURRENT (when used) values of integers $a and $b and starting with 2 and 3
2 We can also use usual assignment operator = in flexible ways
  • @fred = @jeff; # sets two lists equal to each other while
  • @fred= (4,5,@jeff); # defines a list @fred with two more entries than @jeff

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