If you're typing a relative path, you leave off the leading /. (And any '../foo' path is relative.)
If absolute, you include it. When you use '~' it's sneaky because it includes the leading slash, standing for $HOME (/home/username). So when you use that, you're using an absolute path you need to remember has a leading / already.
As far as the trailing slash, it often doesn't matter but it should definitely only have one if a directory is intended, never for a file, of course.
I'm sure there are more details, but those are the factors that spring to mind.
|