in reply to get contents of directory

perldoc -f open
perldoc perlopentut
perldoc -f opendir (and readdir)
Those should enlighten you.

Cheers,
KM