I am an a redhat box and I noticed that if I accidentally type in a dir path without cd in front of it, I get a  /path/to/dir/: Permission denied.; however, I would expect it to say /path/to/dir/: Command not found. Just as if I typed in nonsense like:$ sldkfjsdsldkfjsd: Command not found.What purpose does this have and what would happen if I was to run a dir as a command as a super user (I don't have sudo access)?
Why would running a directory path as a command return permission denied and not command not found?
directory;csh