码迷,mamicode.com
首页 >  
搜索关键字:complex    ( 1359个结果
运算符重载
public struct Complex { public double real; public double imaginary; public Complex(double real, double imaginary) { this.real = real; this.imaginary ...
分类:其他好文   时间:2020-07-07 13:25:18    阅读次数:57
python编程从零基础到项目实践第二章学习(2.3数字和运算符)
数字(Digital)分为整数(Integer)、浮点数(Float)、复数(Complex)、布尔(Boolean) 一:加 + 减 - 乘 * 除 / 取余数 % 幂 ** 只取整数 // print(3+5) #两个数字相加 8print(5-3) #两个数字相减 2print(3*5) #两 ...
分类:编程语言   时间:2020-07-06 01:36:10    阅读次数:99
opencv使用——玉米粒识别和优劣判断
运行环境:python3.6.9 opencv3.4.10 import cv2 import numpy as np font=cv2.FONT_HERSHEY_COMPLEX kernel = np.ones((7,7),np.uint8) img=cv2.imread('corn.jpg',1 ...
分类:其他好文   时间:2020-07-04 22:25:33    阅读次数:72
011 if、while循环
1.类型判断 isinstance:判断数据类型是那种类型;(int,float,bool,complex,str,tuple,set(),dict) 语法:isinstance(值,数据类型) isinstance(值,(str,list,.......)) #isinstance(值,类型)pr ...
分类:其他好文   时间:2020-07-03 21:24:00    阅读次数:78
python---类型转换&二级容器&缓存机制
一.自动类型转换 自动转换遵循规则: 精度从低到高 bool-->int-->float-->complex 例: 1. bool + int res = True + 100 # 1+100 2. bool + float res = True + 3.13 # 1.0+3.13 3. bool ...
分类:编程语言   时间:2020-07-01 20:25:10    阅读次数:70
python---数据类型(int,float,bool,complex),容器类型的基本认识
# ###数据类型:Number(int,float,bool,complex) 1.int 整型 (正整数 0 负整数) intvar = 1111 print(intvar) type 获取值的类型 res = type(intvar)print(res)id 获取一个值的地址res = id( ...
分类:编程语言   时间:2020-06-30 23:01:48    阅读次数:109
210. Course Schedule II
package LeetCode_210 import java.util.* import kotlin.collections.ArrayList /** * 210. Course Schedule II * https://leetcode.com/problems/course-sched ...
分类:其他好文   时间:2020-06-30 22:58:57    阅读次数:116
009 set
set 集合 set 集合: 作用:集合之间的交差并补; 特点:无序,自动去重; 对于set 的值是 可哈希的数值,例如:int float bool complex str tuple 定义集合 setvar = set() #空集合setvar = {'北京','武汉','内蒙古'}print( ...
分类:其他好文   时间:2020-06-30 20:29:51    阅读次数:46
0287. Find the Duplicate Number (M)
Find the Duplicate Number (M) 题目 Given an array nums containing n + 1 integers where each integer is between 1 and n (inclusive), prove that at least ...
分类:其他好文   时间:2020-06-25 09:20:33    阅读次数:64
复杂度
什么是算法? 算法是用于解决特定问题的一系列的执行步骤; 使用不同的算法,解决同一个问题,效率可能相差很大; 比如:求第 n 个斐波那契数 (fibonacci number) // 方法1 public static int fib1(int n) { if (n <= 1) { return 1 ...
分类:其他好文   时间:2020-06-24 10:36:14    阅读次数:50
1359条   上一页 1 2 3 4 5 6 ... 136 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!