提交 c2db5edb 编写于 作者: T twowater

Signed-off-by: twowater <347073565@qq.com>

草根学Python(八) 模块与包
上级 1ddc92aa
<?xml version="1.0" encoding="UTF-8"?>
<module type="PYTHON_MODULE" version="4">
<component name="NewModuleRootManager">
<content url="file://$MODULE_DIR$" />
<orderEntry type="inheritedJdk" />
<orderEntry type="sourceFolder" forTests="false" />
</component>
<component name="TestRunnerService">
<option name="PROJECT_TEST_RUNNER" value="Unittests" />
</component>
</module>
\ No newline at end of file
<component name="InspectionProjectProfileManager">
<settings>
<option name="useProjectProfile" value="false" />
<option name="USE_PROJECT_PROFILE" value="false" />
<version value="1.0" />
</settings>
</component>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectRootManager" version="2" project-jdk-name="Python 3.6.1 (C:\Users\Administrator\AppData\Local\Programs\Python\Python36\python.exe)" project-jdk-type="Python SDK" />
</project>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectModuleManager">
<modules>
<module fileurl="file://$PROJECT_DIR$/.idea/Python8Code.iml" filepath="$PROJECT_DIR$/.idea/Python8Code.iml" />
</modules>
</component>
</project>
\ No newline at end of file
此差异已折叠。
#!/usr/bin/env python3
# -*- coding: UTF-8 -*-
\ No newline at end of file
#!/usr/bin/env python3
# -*- coding: UTF-8 -*-
\ No newline at end of file
#!/usr/bin/env python
# -*- coding: UTF-8 -*-
\ No newline at end of file
#!/usr/bin/env python
# -*- coding: UTF-8 -*-
if __name__ =='__main__' :
print('main')
else :
print('not main')
#!/usr/bin/env python
# -*- coding: UTF-8 -*-
import lname
#!/usr/bin/env python3
# -*- coding: UTF-8 -*-
\ No newline at end of file
#!/usr/bin/env python3
# -*- coding: UTF-8 -*-
def _diamond_vip(lv):
print('尊敬的钻石会员用户,您好')
vip_name = 'DiamondVIP' + str(lv)
return vip_name
def _gold_vip(lv):
print('尊敬的黄金会员用户,您好')
vip_name = 'GoldVIP' + str(lv)
return vip_name
def vip_lv_name(lv):
if lv == 1:
print(_gold_vip(lv))
elif lv == 2:
print(_diamond_vip(lv))
vip_lv_name(2)
#!/usr/bin/env python
# -*- coding: UTF-8 -*-
\ No newline at end of file
#!/usr/bin/env python
# -*- coding: UTF-8 -*-
import sys
print(sys.path)
\ No newline at end of file
#!/usr/bin/env python3
# -*- coding: UTF-8 -*-
\ No newline at end of file
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册