os.path.dirname (os.path.realpath (__ file__))
root, dirs, files
. endswith (
OS is not outside shney library in Python. So I feel like this is the easiest and best way to do it.
This article is provided by Sumit Kumar . If you are as Python.Engineering and would like to contribute, you can also write an article using contribute.python.engineering or by posting an article contribute @ python.engineering. See your article appearing on the Python.Engineering homepage and help other geeks.
Submit new EBook