码迷,mamicode.com
首页 >  
搜索关键字:numbers range    ( 16974个结果
Python 判断段质数
质数:大于1的自然数中,除了1和它本身以外不再有其他因数的自然数 因数:指整数a除以整数b(b≠0) 的商正好是整数而没有余数,我们就说b是a的因数。 num = int(input("输入一个数字: ")) if num > 1: # for i in range(2, num ): 这是我一开始 ...
分类:编程语言   时间:2021-02-26 13:31:27    阅读次数:0
Python:列表(list)
一:作用 二:定义 三:类型转换 四:内置方法 一:列表类型的作用 如果需存多个值并按顺序取,那用list再合适不过了 二:列表类型的定义 l = [1,2,3,'a'] ##相当于l = list(1,2,3,'a') print(l)print(type(l)) 以上代码执行结果为: [1, 2 ...
分类:编程语言   时间:2021-02-26 13:20:23    阅读次数:0
107. Binary Tree Level Order Traversal II
问题: 给定二叉树,进行层序遍历,从底层向上输出。 Example 1: Input: root = [3,9,20,null,null,15,7] Output: [[15,7],[9,20],[3]] Example 2: Input: root = [1] Output: [[1]] Exam ...
分类:其他好文   时间:2021-02-26 12:54:45    阅读次数:0
revitAPI-Autodesk.Revit.DB.Plane“Plane不包含两个参数的构造函数”
将Autodesk.Revit.DB.Plane替换成Autodesk.Revit.DB.Plane.CreateByNormalAndOrigin<!--more--> 1将Autodesk.Revit.DB.Plane替换成Autodesk.Revit.DB.Plane.CreateByNorm ...
分类:数据库   时间:2021-02-25 12:15:11    阅读次数:0
matplotlib.pyplot设置画布主题
import matplotlib.pyplot as plt # 定义一个画图函数 def sinplot(flip = 1): x = np.linspace(0,10,100) for i in range(1,4): y = np.sin(x + i * 0.5) * (4 - i) * f ...
分类:其他好文   时间:2021-02-24 13:05:31    阅读次数:0
MySQL EXPLAIN type 类型说明
数据库版本(select version();): 5.7.32-log sakila 下载地址: https://dev.mysql.com/doc/index-other.html type 表示 MySQL 在表中找到所需行的方式, 又称"访问类型". ALL, index, range, r ...
分类:数据库   时间:2021-02-23 14:29:19    阅读次数:0
3 种进度条 -- 记录
第一种:普通进度条 # 普通进度条 import sys import time def test(): for i in range(1, 101): print('\r', end='') print('Download progress: {}%'.format(i), '▋' * (i//2 ...
分类:其他好文   时间:2021-02-22 11:47:27    阅读次数:0
dhcp搭建
[root@op-benchmark-216 ~]# cat /etc/dhcp/dhcpd.conf # dhcpd.conf # # Sample configuration file for ISC dhcpd # # option definitions common to all supp ...
分类:其他好文   时间:2021-02-20 12:34:38    阅读次数:0
用Python画一颗心、小人发射爱心(附源码)
先画一个爱心, 源代码: #!/usr/bin/env python # -*- coding:utf-8 -*- import turtle import time # 画心形圆弧 def hart_arc(): for i in range(200): turtle.right(1) turtl ...
分类:编程语言   时间:2021-02-20 12:23:41    阅读次数:0
Python入门随记(2)
1、二维列表的声明 [['pygis'],['gis']] 2、CSV格式的本质,是用,作为分隔符。 3、for循环 for …… in …… 例: a=0 for i in range(100): a+=a print(a) 4、引用库的方法为import 5、将句子分割词语的方法 import ...
分类:编程语言   时间:2021-02-20 11:45:10    阅读次数:0
16974条   上一页 1 ... 16 17 18 19 20 ... 1698 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!