I have two string arrays in my PowerShell script:
$search = @('File1', 'File2');
$paths = @('C:\Foo\File1.pdf', 'C:\Foo\Bar.doc', 'C:\Foo\File2.txt');
How can I get all file paths which contain the file names from the search array? Can this be done in a pipeline?