Basic python: Search Path and basic python path
How can I add a written script or module to the python search path?
>>> Import sys >>> sys. path ['', '/Library/Frameworks/Python. framework/Versions/3.4/lib/python34.zip ','/Library/Frameworks/Python. framework/Versions/3.4/lib/python3.4 ','/Library/Frameworks/Python. framework/Versions/3.4/lib/python3.4/plat-darwin', '/Library/Frameworks/Python. framework/Versions/3.4/lib/python3.4/lib-dynload ','/Library/Frameworks/Python. framework/Versions/3.4/lib/python3.4/site-packages '] # A path list is displayed, where python searches for paths, the module should be stored in/Library/Frameworks/Python. framework/Versions/3.4/lib/python3.4/site-packages >>> sys. path. append ("/desktop/python3.4/test. py ") # test. add the path of py to the python search path> sys. path ['', '/Library/Frameworks/Python. framework/Versions/3.4/lib/python34.zip ','/Library/Frameworks/Python. framework/Versions/3.4/lib/python3.4 ','/Library/Frameworks/Python. framework/Versions/3.4/lib/python3.4/plat-darwin', '/Library/Frameworks/Python. framework/Versions/3.4/lib/python3.4/lib-dynload ','/Library/Frameworks/Python. framework/Versions/3.4/lib/python3.4/site-packages ','/desktop/python3.4/test. py'] >>> import test "Hellow world"