【问题标题】:How to setup python 2.7 features into Python 2.6?如何将 python 2.7 功能设置到 Python 2.6 中?
【发布时间】:2011-10-19 23:05:58
【问题描述】:

我目前的工作是在 Windows 环境中使用 Python 2.6。但我对 Python 2.7 中添加的一些特性很感兴趣。 是否可以将某些功能(特别是“Collections.OrderedDict”)从 2.7 移动到 2.6?如果是这样,我们该怎么做?

【问题讨论】:

    标签: python windows python-2.7


    【解决方案1】:

    看看http://pypi.python.org/pypi/ordereddict

    它被宣传为

    Py2.7 的新 collections.OrderedDict 的替代品 适用于 Python 2.4-2.6。

    【讨论】:

    • 得到它的包。我知道如何在 Windows 操作系统中设置吗?我是否必须将该文件粘贴到站点包中?或者有没有其他安装方式?
    • 谢谢..我用 cmd 安装它。而且我们也有像“from collections import OrderedDict” 和 from ordereddict import OrderedDict pypi ;-) 之类的区别
    猜你喜欢
    • 2011-02-02
    • 1970-01-01
    • 2013-11-28
    • 2016-09-07
    • 2015-05-17
    • 1970-01-01
    • 2017-01-17
    • 1970-01-01
    • 2018-04-21
    相关资源
    最近更新 更多