Answers for "python path set tot parent directory"

0

How do I get the parent directory in Python?

from pathlib import Path
Path(Path.cwd()).parent
Posted by: Guest on November-29-2020
2

python get parent directory

from pathlib import Path
Path('C:Program Files').parent
Posted by: Guest on January-22-2020

Python Answers by Framework

Browse Popular Code Answers by Language