Bmdtools.pm functions

max
You know what &max() and &min() do. You can supply as many inputs as you want.
Usage:
my $max = Bmdtools::max(2, 4, 6);

min
You know what &max() and &min() do. You can supply as many inputs as you want.
Usage:
my $min = Bmdtools::min(2, 4, 6);

commonelements
Examines two arrays for common elements. Returns a list of those common elements along with a list of elements that are unique to the first array and a list or those unique to the second array. All arrays are passed and returned by reference.
Usage:
my($common, $onlyin1, $onlyin2) = Bmdtools::commonelements([@array1], [@array2]);
print "@$common\n";
print "@$onlyin1\n";
print "@$onlyin2\n";

cleanpath
Cleans up file specifications by removing unnecessary slashes and dots without damaging "http://" protocol prefixes.
Usage:
my $filename = Bmdtools::cleanpath("http://./news.mdir/////news.sch/");