Absolute paths
Absolute file paths start at the root.
That means they must have the path separator as the very first character, because that is really the name of the root directory.
/ada/data
Click or tap a directory to see the path from root to that directory.
Absolute paths are useful because they work independently of what the current directory is.
One disadvantage of absolute paths is that they can be quite long. When you’re working with files a long way from the root, this can be inconvenient.
Another problem is that — almost by definition — they rely on the file structure being exactly as described. This is why you should avoid using absolute paths in any programs you write: absolute paths will only work on another computer if it has exactly the same path as the one you’ve written yours on.
Relative paths address both these disadvantages.