use Pick;
Pick::single("File name", "index.html");
will display the following:
File name [index.html]>
and wait for input. If the user hits Return, it will return "index.html"
if the user types in a text string and hits return, the text string will be returned,
not including the trailing newline.
use Pick;
Pick::list("Pick a fruit", ["apple", "pear", "pineapple"], 3);
will display the following:
[1] apple
[2] pear
[3] pineapple
Pick a fruit [3]>
If the user just hits Enter, ``pineapple'' (the default value) will be returned.
Note that 3 marks the 3rd element of the list, and is not an index value
into the array.
If the user enters 1, 2 or 3, the corresponding text string
("apple", "pear", "pineapple" will be returned by Pick::list().
Copyright 2002 by Mike Schilli, all rights reserved.
This program is free software, you can redistribute it and/or
modify it under the same terms as Perl itself.