Fellow monks,
I have come across a problem that I cannot explain. In the following code I am using the system command to read in two points from a database. For some reason, both values, $a and $b are being printed out. If I comment out the last line, just one value is printed to the screen. But with the last line in, it prints out the value of $a and $b. How can $b be printed out when it has not even read the point yet? I'm using version 5.6. Any ideas?
#!/usr/local/bin/perl -w
use diagnostics;
my $a = system "read_apt db_1";
print $a;
my $b = system "read_apt db2";