python __builtins__ complex类 (13)
13、'complex', 函数用于创建一个值为 real + imag * j 的复数或者转化一个字符串或数为复数。如果第一个参数为字符串,则不需要指定第二个参数。
class complex(object)| complex(real[, imag]) -> complex number| | Create a complex number from a real part and an optional imaginary part.| This is equivalent to (real + imag*1j) where imag defaults to 0. # 创建一个复数,实数部分是第一个参数,虚部是第二个参数,虚部默认为0.| | Methods defined here:| | __abs__(self, /)| abs(self)| | __add__(self, value, /)| Return self+value.| | __bool__(self, /)| self != 0| | __divmod__(self, value, /)| Return divmod(self, value).| | __eq__(self, value, /)| Return self==value.| | __float__(self, /)| float(self)| | __floordiv__(self, value, /)| Return self//value.| | __format__(...)| complex.__format__() -> str| | Convert to a string according to format_spec.| | __ge__(self, value, /)| Return self>=value.| | __getattribute__(self, name, /)| Return getattr(self, name).| | __getnewargs__(...)| | __gt__(self, value, /)| Return self>value.| | __hash__(self, /)| Return hash(self).| | __int__(self, /)| int(self)| | __le__(self, value, /)| Return self<=value.| | __lt__(self, value, /)| Return self<value.| | __mod__(self, value, /)| Return self%value.| | __mul__(self, value, /)| Return self*value.| | __ne__(self, value, /)| Return self!=value.| | __neg__(self, /)| -self| | __new__(*args, **kwargs) from builtins.type| Create and return a new object. See help(type) for accurate signature.| | __pos__(self, /)| +self| | __pow__(self, value, mod=None, /)| Return pow(self, value, mod).| | __radd__(self, value, /)| Return value+self.| | __rdivmod__(self, value, /)| Return divmod(value, self).| | __repr__(self, /)| Return repr(self).| | __rfloordiv__(self, value, /)| Return value//self.| | __rmod__(self, value, /)| Return value%self.| | __rmul__(self, value, /)| Return value*self.| | __rpow__(self, value, mod=None, /)| Return pow(value, self, mod).| | __rsub__(self, value, /)| Return value-self.| | __rtruediv__(self, value, /)| Return value/self.| | __str__(self, /)| Return str(self).| | __sub__(self, value, /)| Return self-value.| | __truediv__(self, value, /)| Return self/value.| | conjugate(...)| complex.conjugate() -> complex| | Return the complex conjugate of its argument. (3-4j).conjugate() == 3+4j.| | ----------------------------------------------------------------------| Data descriptors defined here:| | imag| the imaginary part of a complex number| | real| the real part of a complex number
转载于:https://www.cnblogs.com/gundan/p/8243950.html
python __builtins__ complex类 (13)相关推荐
- python __builtins__ float类 (25)
25.'float', 用于将整数和字符串转换成浮点数. class float(object)| float(x) -> floating point number| | Convert a ...
- python __builtins__ set类 (60)
60.'set', 转换为集合类型 class set(object)| set() -> new empty set object| set(iterable) -> new set ...
- python __builtins__ credits类 (15)
15.'credits', 信用 class _Printer(builtins.object)| interactive prompt objects for printing the licens ...
- python __builtins__ frozenset类 (27)
27.'frozenset', 返回一个冻结的集合,冻结后集合不能再添加或删除任何元素. class frozenset(object)| frozenset() -> empty frozen ...
- python __builtins__ copyright类 (14)
14.'copyright', 版权 class _Printer(builtins.object)| interactive prompt objects for printing the lice ...
- python __builtins__ str类 (65)
65.'str', 字节转换成字符串.第一个传入参数是要转换的字节,第二个参数是按什么编码转换成字符串 class str(object)| str(object='') -> str| str ...
- python __builtins__ bytes类 (8)
8.'bytes', 字符串转换成字节流.第一个传入参数是要转换的字符串,第二个参数按什么编码转换为字节. class bytes(object)| bytes(iterable_of_ints) - ...
- Python基础之:Python中的类
文章目录 简介 作用域和命名空间 class 类对象 类的实例 实例对象的属性 方法对象 类变量和实例变量 继承 私有变量 迭代器 生成器 简介 class是面向对象编程的一个非常重要的概念,pyth ...
- Python模块与类
2019独角兽企业重金招聘Python工程师标准>>> 类 类的定义,继承 类中的属性,类属性和实例属性的区别及访问方式 变量名以"_"或"__&quo ...
最新文章
- boost::fusion::fused用法的测试程序
- 牛客 - lglg说要有题,于是便有了题。(欧拉线性筛+打表+思维)
- ajax的data传参的两种方式
- 传入一个MapString,Long 返回它按value排序后的结果
- Linux查询pg数据库账号密码,PostgreSQL登录数据库
- ckeditor编辑的使用方法
- Redis基础(七)——事件、服务器、客户端、多线程
- 【工程项目经验】mac电脑lldb调试工具
- 那年学过的Java笔记三核心类库二
- SpringBoot中关于Mybatis使用的三个问题
- 小型制造类企业IT云平台
- 双线性映射(Bilinear Maps)实现(有限域、循环群)
- coreos 安装 mysql_在 UOS 上体验 CoreOS
- Docker Wnmp 搭建
- 包政讲营销录音(3)
- AUTOCAD——调整十字光标、CAD表格文字对齐方式
- 什么是机器人的外部轴?
- 摘:一张废手机卡的作用
- 【每日一读】Sampling Multiple Nodes in Large Networks: Beyond Random Walks
- with open相关用法