推荐学习书目
› 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
wyntergreg
V2EX  ›  Python

如何机智的解释"there is only one way to do it"?

  •  
  •   wyntergreg · Mar 17, 2017 · 2239 views
    This topic created in 3529 days ago, the information mentioned may be changed or developed.

    给测试部的同事培训 Python 基础,我把这句列在语言特点中了,讲到这里的时候脑子突然闪过字符串赋值单双引号,大脑瞬间尴尬后直接讲"任何事物都有打脸的一面,比如字符串赋值..."囧

    PythonAnswer
    PythonAnswer
    Mar 17, 2017 via Android
    1
    字符串引号是可以活用的。

    one best way to do it, called pythonic way
    wyntergreg
    wyntergreg
    OP
    Mar 17, 2017
    2
    @PythonAnswer 如何活法,明明是单双引号通用么, python3 默认字符串双引号会转为单引号
    不过嵌套用的时候则按照定义顺序来,是否就是活在这了...手动滑稽
    hihihihihi
    hihihihihi
    Mar 17, 2017
    3
    never say never!
    msg7086
    msg7086
    Mar 18, 2017
    4
    只有一种最好的做法。
    至于哪种是最好的做法,可以吵几年。
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Privacy   ·   Solana   ·   1764 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 26ms · UTC 01:03 · PVG 09:03 · LAX 17:03 · JFK 20:03
    ♥ Do have faith in what you're doing.