I have created an array as follows
while (defined ($line = ``)) { chomp ($line); push @stack,($line); }
#!/usr/bin/perl use strict; use warnings; open IN, "< read.txt" or die "Can't read in 'read.txt'!"; my $content = join '', ; while ($content =~ m`(\d+)`g) { print "$1\n"; }