li = {"alex"," aric","Alex","Tony","rain"}for i,j in enumerate(li,1): new_j = j.strip() print(i,new_j) RESTART: C:/Users/wssar/AppData/Local/Programs/ ...
分类:
编程语言 时间:
2018-10-27 19:53:12
阅读次数:
235
参考资料: https://www.cnblogs.com/kissdodog/archive/2013/01/29/2882195.html https://www.cnblogs.com/maj99/p/6322626.html IEnumerable:所有集合都要继承IEnumerable。I ...
Special Kinds of Methods Methods associated with a type rather than an instance of a type must be marked with the static declaration modifier for enum ...
分类:
编程语言 时间:
2018-10-26 16:17:56
阅读次数:
206
$git push origin master 报错: 执行:$git pull 命令,没有将项目更新,并提示下图: 执行本地关联远程分支命令: git branch --set-upstream-to=origin/remote_branch your_branch 其中,origin/remot ...
分类:
其他好文 时间:
2018-10-24 19:52:01
阅读次数:
739
<!-- flowchart 箭头图标 勿删 --> 平时,我们将c#中的Distinct大多用于对数组去重,一般数组为基础的数据类型,例如 int,string.也可以用于对象去重,我们看看C#对Distinct方法的定义: 有重载,第一个参数都加了this,是拓展方法,有关拓展方法,请百度了解。 ...
分类:
其他好文 时间:
2018-10-24 16:00:12
阅读次数:
155
product_list=[(‘iPhone‘,5800),(‘Macpro‘,9500),(‘Bike‘,800),(‘Watch‘,10600),(‘Coffee‘,31),(‘AlexPython‘,120)]shopplist_list=[]salary=input("Inputyou
分类:
其他好文 时间:
2018-10-24 15:56:26
阅读次数:
117
前一阵用shell写了一个从数据库中抽取数据生成.xml文件的脚本,要求是每个文件中只生成1000条数据。于是用到了while read line 作为循环。 在制作文件计数器的时候发现了一个问题,在执行的过程中文件计数器(FILENUM)总是出现返回初始值的现象,具体简化的脚本如下: 基本流程如上 ...
分类:
其他好文 时间:
2018-10-24 15:29:21
阅读次数:
205
语法 参数说明: obj:必需。目标对象 prop:必需。需定义或修改的属性的名字descriptor:必需。目标属性所拥有的特性 返回值: 传入函数的对象。即第一个参数obj。 针对属性,我们可以给这个属性设置一些特性,比如是否只读不可以写;是否可以被for..in或Object.keys()遍历 ...
分类:
Web程序 时间:
2018-10-24 12:10:50
阅读次数:
120
using System.Collections; using System.Collections.Generic; using UnityEngine; using UnityEngine.Serialization; [AddComponentMenu("Sample/TestCode")] ... ...
分类:
编程语言 时间:
2018-10-23 14:40:08
阅读次数:
168