首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 开发语言 > perl python >

在python里面,数学上那个 e=2.718 math库里面有定义吗?解决方案

2012-04-25 
在python里面,数学上那个 e2.718math库里面有定义吗?如题[解决办法] from math import e e2.718281

在python里面,数学上那个 e=2.718 math库里面有定义吗?
如题

[解决办法]
>>> from math import e
>>> e
2.718281828459045
>>>
[解决办法]
也可以这样:

Python code
Python 3.2.3 (default, Apr 11 2012, 07:15:24) [MSC v.1500 32 bit (Intel)] on win32Type "copyright", "credits" or "license()" for more information.>>> import math>>> math.e2.718281828459045>>> 

热点排行