《Python 简明教程》翻译问题——2.4 基本语法(已解决)
有问题的句子:
在 Python 中
format
方法的作用就是将每一个参数值替换为规范的位置。
这句话,已经被我修改。
原句为:
Python 在
format
方法中的作用是它将每个参数值替换为规范的位置。
当读到这句话时,我认为它是有问题的。因为在我看来, Python
和 format()方法
的位置颠倒了。应该把 format()方法
放在主语的位置, Python
放在状语的位置。
但是,我找到了英语原文:
What Python does in the
format
method is that it substitutes each argument value into the place of the specification.
这说明我的想法可能是错误的,但是我不明白哪里出了问题。
期待大家的解疑答惑。
文章链接:
2.4基本语法
很多语言都有输出
format
格式化.string.format(formatstring, items)