#!/usr/bin/perl my $size=1E6; my $f = 2; print "Increasing memory print each step by a factor $f\n\n"; while(1){ print "\tCreating array of $size items...Press enter to continue...."; my $b = ; my @a=1..$size; print "...done. Press enter to continue."; $b = ; chomp $b; $b=~ /[qxQX]/ and exit; $size *= $f; }