- 博客(11)
- 收藏
- 关注
原创 py4e第10节习题
0.2 Write a program to read through the mbox-short.txt and figure out the distribution by hour of the day for each of the messages. You can pull the hour out from the 'From ’ line by finding the time and then splitting the string a second time using a colo
2021-12-29 19:27:19
372
原创 py4e 9.4 习题
py4e 9.4Write a program to read through the mbox-short.txt and figure out who has sent the greatest number of mail messages. The program looks for 'From ’ lines and takes the second word of those lines as the person who sent the mail. The program creates
2021-12-13 19:15:43
662
原创 【无标题】
8.4 Open the file romeo.txt and read it line by line. For each line, split the line into a list of words using the split() method. The program should build a list of words. For each word on each line check to see if the word is already in the list and if n
2021-11-29 19:06:07
223
原创 py4e.Character 7
py4e.Character 7Write a program that prompts for a file name, then opens that file and reads through the file, looking for lines of the form:X-DSPAM-Confidence: 0.8475Count these lines and extract the floating point values from each of the lines and com
2021-11-21 23:57:28
247
原创 2021-11-06
iteration variable(迭代变量):用于遍历循环for i in [‘aaa’,‘bbb’,‘cccc’], i is iteration variable.e.g: for letter in ‘banana’ :print(letter)其中的iteration variable是letter即for i in ’ ',i是迭代变量
2021-11-06 18:37:18
121
原创 关于unity中can‘t add scrip
假设有两个文件,命名为1与2,把1的内容完全删空把2的内容贴上去,会提示can't add scrip。但是如果1保留public class 1 : MonoBehaviour{},仅删除{}内的内容,再填入2的内容,就可以运行。
2021-09-30 10:18:21
102
原创 2021-09-29
转载C#中的小数表述:“errorCS1503: Argument1: cannot convert from ‘double’ to float因为导入的模型是0.01倍的,所以在处理距离的时候会用到小数,而C#语法里默认是双精度double,而不是float,所以在处理float数据时要在小数的后边加f”...
2021-09-29 20:41:26
86
原创 This request has been blocked; the content must be served over HTTPS
如果上传GitHub,点击page页面出现空白页面,并且控制台报错“This request has been blocked; the content must be served over HTTPS”,在html文件头部加上:<meta http-equiv="Content-Security-Policy" content="upgrade-insecure-requests"&...
2020-04-20 19:02:19
599
原创 用js实现在Chrome里换行
<button id="btn" onclick="get()">pop-up</button><div id="a"></div><script>function get(){ var btn = document.getElementById("btn"); var p = document.ge...
2020-04-19 21:24:44
390
1
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人