on my system(win2k server, python 2.3.5),[''C:\\'', ''C:\\WINNT\\system32\\python23.zip'',''C:\\Python23\\lib\\site-packages\\Pythonwin'',''C:\\Python23\\lib\\site-packages\\win32'',''C:\\Python23\\lib\\site-packages\\win32\\lib'',''C:\\Python23\\lib\\site-packages'', ''C:\\Python23\\DLLs'',''C:\\Python23\\lib'', ''C:\\Python23\\lib\\plat-win'',''C:\\Python23\\lib\\lib-tk'', ''C:\\Python23'', ''D:\\Program Files\\DeLanoScientific\\PyMOL\\modules'']now, i wanna add "C:\Python23\Pmw\Pmw_1_2\lib" into sys.path, how?any help would be appreciated.with my kind regards,Wen 解决方案 [''C:\\'', ''C:\\WINNT\\system32\\python23.zip'', ''C:\\Python23\\lib\\site-packages\\Pythonwin'', ''C:\\Python23\\lib\\site-packages\\win32'', ''C:\\Python23\\lib\\site-packages\\win32\\lib'', ''C:\\Python23\\lib\\site-packages'', ''C:\\Python23\\DLLs'', ''C:\\Python23\\lib'', ''C:\\Python23\\lib\\plat-win'', ''C:\\Python23\\lib\\lib-tk'', ''C:\\Python23'', ''D:\\Program Files\\DeLano Scientific\\PyMOL\\modules''] now, i wanna add "C:\Python23\Pmw\Pmw_1_2\lib" into sys.path, how? any help would be appreciated.hint 1: Python lists have an append() and an insert() methodhint 2: sys.path is a listHTH--bruno desthuillierspython -c "print ''@''.join([''.''.join([w[::-1] for w in p.split(''.'')]) forp in ''o****@xiludom.gro''.split(''@'')])" 这篇关于如何在sys.path中添加新路径?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持! 上岸,阿里云! 06-13 22:24