note
shmem
First thing to do, read [doc://perlform] and [doc://perlvar] :-)
<p>Just select the format you like assigning to <code>$~</code>. Example:
<code>
#!/usr/bin/perl
our(@l,$c);
while(@l = getpwent) {
$~ = $c++ % 2 ? 'foo' : 'bar';
write;
}
format foo =
left @<<<<<<<<<<<< @<<<<<<<<<<<<
$l[0],$l[7]
.
format bar =
right @>>>>>>>>>>> @>>>>>>>>>>>>
$l[0],$l[7]
.
</code>
<!-- Node text goes above. Div tags should contain sig only -->
<div class="pmsig"><div class="pmsig-510280">
<small><pre>_($_=" "x(1<<5)."?\n".q·/)Oo. G°\ /
/\_¯/(q /
---------------------------- \__(m.====·.(_("always off the crowd"))."·
");sub _{s./.($e="'Itrs `mnsgdq Gdbj O`qkdq")=~y/"-y/#-z/;$e.e && print}</pre></small>
</div></div>
559248
559248