use strict;
use warnings;
my $string = "abc";
while( $string =~ /b/g ) {
print $#-, "\n";
}
First Time - Output is: 808482816
Secind Time(and everytime after in the same command prompt session) - Output is: 262149
Win2K SP4
This is perl, v5.8.6 built for MSWin32-x86-multi-thread
(with 3 registered patches, see perl -V for more detail)
Copyright 1987-2004, Larry Wall
Binary build 811 provided by ActiveState Corp. http://www.ActiveState.
+com
ActiveState is a division of Sophos.
Built Dec 13 2004 09:52:01
Perl may be copied only under the terms of either the Artistic License
+ or the
GNU General Public License, which may be found in the Perl 5 source ki
+t.
Complete documentation for Perl, including FAQ lists, should be found
+on
this system using `man perl' or `perldoc perl'. If you have access to
+ the
Internet, point your browser at http://www.perl.org/, the Perl Home Pa
+ge.