$
$*********************************************      basic stuff
$
&device -g_default device -oecho no
&dimen -dimen feet kips
&default -depth 100
$
$*********************************************      read macros
$
&insert sfun.mac
$
$*********************************************      format
$
&cutype Testing &FORMAT
&type format UPPER   = &format(upper puppy dog cow)
&type format LOWER   = &format(lower PUPPY DOG COW)
&type format FIRST   = &format(first puppy dog cow)
&type format COMMA   = &format(comma puppy dog cow)
&device -and_word et
&type format COMMA   = &format(comma puppy dog cow)
&type format COMMA   = &format(comma dog cow)
&set pi = 3.1591467
&type format I3  |&format(I3 %pi)|
&loop w 3 8
   &set a = a%w
   &type             12345678901234567890
   &type format %a  |&format(%a %pi)|
   &type                12345678901234567890
   &loop d 0 %w-3
       &set f = f%(w).%d
       &type format %f  |&format(%f %pi)|
   &endloop
&endloop
&type &format(a8 12345678) &format(a8 12345678) &format(a8 12345678)
&type &format(a8 12345678) &format(a8         ) &format(a8 12345678)
$
$*********************************************      all done
$
&fini
