in reply to This is why Perl is so frustrating

I'm not sure what you're trying to do - I'm guessing you want to skip the directories '.' and '..'. Assuming that, then I think you are "MISSING A FUNDAMENTAL ASPECT OF LOGICAL OPERATIONS".

You need to 'and', not 'or'. The way it's written (or), first time through, $file = '.', which makes the first half of the if statement false. However, $file = '.', so it can't equal '..', which makes the second part of the if statement true ($file ne '..' <==, yes, that's correct, because $file = '.'). Now you OR 1 and 0 and get a true condition; thus execute the if statement.