use FileMan; use Cwd; my $fileman = new FileMan; my $first_path = $fileman->FindPath('file1.txt', cwd); my $second_path = $fileman->FindPath('file2.txt', cwd); #### sub FindPath { #- Var Declaration And Initialization my ($hr_self, $file_name, $file_path) = @_; # Array to fill with file paths my @a_files = (); # Search file_path for the file find(\&ProcessFile, $file_path); #- The Subroutine To Process Files And Directories sub ProcessFile {if ($_ eq $file_name){push (@a_files, $File::Find::name);}} # Return the paths found return @a_files; } # end FindPath