1.迭代器 对于遍历集合元素,Kotlin 标准库支持 迭代器 的常用机制?对象可按顺序提供对元素的访问权限,而 不会暴露集合的底层结构。当需要逐个处理集合的所有元素(例如打印值或对其进行类似更新)时,迭代 器非常有用。 Iterable<T> 接口的继承者(包括 Set 与 List )可以通过调 ...
分类:
其他好文 时间:
2020-07-02 16:42:42
阅读次数:
37
前言 ORM是什么?:(在django中,根据代码中的类自动生成数据库的表也叫--code first) ORM:Object Relational Mapping(关系对象映射) 类名对应 》数据库中的表名 类属性对应 》数据库里的字段 类实例对应 》数据库表里的一行数据 obj.id obj.n ...
分类:
其他好文 时间:
2020-07-02 16:14:01
阅读次数:
55
from pandas import Series; #定义,可以混合定义 x = Series(['a', True, 1], index=['first', 'second', 'third']); x = Series(['a', True, 1]); #追加一个序列 n = Series([ ...
分类:
其他好文 时间:
2020-07-01 23:51:23
阅读次数:
49
先执行:Enable-Migrations,会生成Migrations-》Configuration.cs 再执行:Add-Migrations InitialCreate – IgnoreChanges,会生成空************_InitialCreate.cs,忽略初始化 再执行:Upd ...
分类:
数据库 时间:
2020-07-01 14:24:34
阅读次数:
77
给你两个有序整数数组 nums1 和 nums2,请你将 nums2 合并到 nums1 中,使 nums1 成为一个有序数组。 说明: 初始化 nums1 和 nums2 的元素数量分别为 m 和 n 。你可以假设 nums1 有足够的空间(空间大小大于或等于 m + n)来保存 nums2 中的 ...
分类:
编程语言 时间:
2020-07-01 12:39:56
阅读次数:
47
1、FBM320控制寄存器 a、AD数据寄存器地址(24bit数据): 0xF6:Data-LSB 0xF7:Data-CSB 0xF8:Data-MSB b、CONFIG寄存器地址(0xF4): OSR(bit6-bit7):00=1024X;01=2048X;10=4096X;11=8192X ...
分类:
其他好文 时间:
2020-07-01 11:05:19
阅读次数:
86
我们在使用python的flask框架时,可能会经常用到生命周期函数如:before_request, before_first_request,或者信号等,刚开始学的时候就想只要写一个函数,然后加上一个装饰器居然就可以实现这种开挂般的效果,那时感觉这框架代码写得真棒, 再过些时间自己学会阅读框架源 ...
分类:
编程语言 时间:
2020-06-30 14:41:29
阅读次数:
70
A few weeks ago we introduced the first demonstration of “P4 Runtime”. We invite all members of the networking community to join with us, so that toge ...
分类:
其他好文 时间:
2020-06-30 13:01:44
阅读次数:
51
Jump Game II (H) 题目 Given an array of non-negative integers, you are initially positioned at the first index of the array. Each element in the array r ...
分类:
其他好文 时间:
2020-06-30 09:14:16
阅读次数:
59
高效能人士的七个习惯: 习惯一:积极主动 Be Proactive 习惯二:以始为终 Begin with the end in mind 习惯三:要事第一 Put first things first 习惯四:双赢思维 Think win/win 习惯五:知彼解己 Seek first to un ...
分类:
其他好文 时间:
2020-06-29 22:49:01
阅读次数:
119