[Israel.pm] Echo-ing commands to the standard output
David Rachamim
David.Rachamim at ceva-dsp.com
Sun Feb 27 08:26:30 PST 2005
Hi All,
Is there a way to have Perl echo the commands it gets to the standard
output (or to any other place) before it executes them?
The following example may explain what I mean:
The script:
-----------
print "Hello\n";
for (1..3)
{
print "$_\n";
}
The output (should be something generally like this):
-----------------------------------------------------
print "Hello\n";
Hello
for (1..3)
{
print "$_\n";
}
print "$_\n";
1
print "$_\n";
2
print "$_\n";
3
--------------------
Thanks,
David
More information about the Perl
mailing list