realpath() expands all symbolic links and resolves references to '/./', '/../' and extra '/' characters in the input path. and return the canonicalized absolute pathname.
Returns the canonicalized absolute pathname on success. The resulting path will have no symbolic link, '/./' or '/../' components.
The above example will output: