in reply to Re: Re: format question
in thread format question
Consider the following example based on your code snippet:
This gives the following output. Note the additional line in Run 2.#Something tells me we're not programming in Perl anymore Toto. ;-) for (1..2) { print "Run: ", $_, "\n"; $^A = ""; formline(<<'OUTPUT_TABLE', 1, 2); @<<<<<<< @<<<<<<<<<<<< @<<<<<<< @<<<<<<<<<<<<~ OUTPUT_TABLE $out .= $^A; print $out; } for (3..4) { print "Run: ", $_, "\n"; $^A = ""; formline(<<'OUTPUT_TABLE', 1, 2); @<<<<<<< @<<<<<<<<<<<< @<<<<<<< @<<<<<<<<<<<<~ OUTPUT_TABLE print $^A; }
Therefore, you will have to re-organise your code to make sure that you print $^A.Run: 1 1 2 Run: 2 1 2 1 2 Run: 3 1 2 Run: 4 1 2
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Re: Re: format question
by Anonymous Monk on Nov 09, 2001 at 08:42 UTC |