Paths and text files

Which file is selected?

Examples

Worked example

Input
The current directory is /work and the relative path is data/notes.txt.
Expected output
/work/data/notes.txt

Hints and solution

Hint 1

Write down the starting state and walk through one example by hand.

Reveal worked answer

The current directory supplies the starting point for the relative path.

Back to the lesson