V2EX = way to explore
V2EX 是一个关于分享和探索的地方
Sign Up Now
For Existing Member  Sign In
推荐学习书目
Learn Python the Hard Way
Python Sites
PyPI - Python Package Index
http://diveintopython.org/toc/index.html
Pocoo
值得关注的项目
PyPy
Celery
Jinja2
Read the Docs
gevent
pyenv
virtualenv
Stackless Python
Beautiful Soup
结巴中文分词
Green Unicorn
Sentry
Shovel
Pyflakes
pytest
Python 编程
pep8 Checker
Styles
PEP 8
Google Python Style Guide
Code Style from The Hitchhiker's Guide
sevenQu
V2EX  ›  Python

vs code Python :current file 调试和在控制台 Python 该文件名调用有什么区别吗?为什么在控制台可以得出结果,直接调试一直处于调试,没有结果

  •  
  •   sevenQu · Jul 7, 2018 · 1839 views
    This topic created in 2852 days ago, the information mentioned may be changed or developed.
    from stardict import DictCsv
    dictionary=DictCsv('ecdict.csv')
    a=dictionary.query(10)
    print(a)
    

    就是这段简单的代码,查询一个英文字典,希望有人可以指点一下,谢谢

    Wicked
        1
    Wicked  
       Jul 7, 2018 via iPhone
    if __name__ == “ maim ”:
    # your code here
    试试
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   3906 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 37ms · UTC 10:28 · PVG 18:28 · LAX 03:28 · JFK 06:28
    ♥ Do have faith in what you're doing.