in reply to Some help with a lottery picking program

I have implemented a lot of your suggestions above, and made the code below. Its not a serious program/project but something I wrote purely for people to critique, and you have all been very helpfull - I will remember to implement these techniques in future, thanks a lot.
#!/usr/bin/perl use strict; print qq( ------------------------------------------------------- National Lottery Number Picker ------------------------------------------------------- How many lines do you want to play? ); print "Lines.....:"; my $lines = <STDIN>; my @lines; my @line; die "Good. Don't waste your money!\n" unless $lines; my @numbers = (1..49); srand; print "\n"; &chooseline(); my $i = 1; ######################################## # Generate The Line(s) sub chooseline { while ($i < $lines) { &genline(); push @lines, @line; $i++; if ($i eq $lines) { print "\n\n"; last; } } print "\n\n"; } ######################################### # Generate the numbers sub genline { @line = ''; my $e = 1; while ($e ne "7") { my $index = rand @numbers; my $element = $numbers[$index]; print " $element"; if ($e eq "6") { print "\n"; push @line, $element; my $newline = "\n"; push @line, $newline; last; } else { push @line, $element; } $e++; } } print "(E)mail Results / (Q)uit\n\n"; print "Action....:"; my $action = <STDIN>; exit if $action =~ /^Q/i; if ($action =~ /^E/i) { print "\nEmail address...:"; my $email; $email = <STDIN>; chomp($email); die "Don't bother then, bye!" if !$email; print ("$email, is this correct? (y/n)...:"); my $dcheck = <STDIN>; exit if $dcheck =~ /^n/i; open (MAIL, "|/usr/sbin/sendmail -t"); print MAIL "To: $email\n"; print MAIL "From: Lottery Generator\n"; print MAIL "Subject: Your Lottery Numbers\n"; foreach my $lin (@lines) { print MAIL "$lin "; } close (MAIL); }