#!/usr/bin/perl -w # This script should ask for a list, a number, then display # the line entered of the list in reference to the number print "Hello, please enter a list:/n"; @list=<>; chomp @list; print "Now, enter a number:/n"; $number=<>; chomp $number; # OK, now print the results print "Line $number was: $list[$number-1]";