-
Python:数据类型---集合的增删查与交并差集
所属栏目:[Python] 日期:2020-12-17 热度:79
1、基础数据类型汇总补充 1,list: 在循环一个列表是,最好不能删除列表中的元素。 2,bool 空列表、int:0、空str、空dict、空set---》bool:false 其余为true 3,dict dic = dict.fromkeys([1,2,3],'春哥') print(dic) 面试题: tu1 =(1)----->int tu2[详细]
-
Python:一些小知识
所属栏目:[Python] 日期:2020-12-17 热度:171
小知识点总结 一、Python2与Python3?的区别 1、Python2中可以加括号输出,也可不加输出 ? ? Python3中必须加 2、python2?中有xrange(生成器)也有range ? ? python3中只有range 3、python2中的input为raw_input ? ? ?python3?中为input 二、‘=’与is的区别[详细]
-
Python:dict字典
所属栏目:[Python] 日期:2020-12-17 热度:64
#字典dict-------》唯一的映射类型 1、数据类型的划分 数据类型划分为可变数据类型和不可变数据类型。 不可变数据类型:tupe(元组)、bool、int、str? ? ? ? ? ?可哈希 可变数据类型:list、dict、set(集合)? ? ? ? ? ? ? ? ?不可哈希 dict(key,value)[详细]
-
Python:数据类型---list的增删改查
所属栏目:[Python] 日期:2020-12-17 热度:158
li=[ ,[1,2,3], , , , ] l1 = (l1) l2 = li[1 (l2) l3=li[0:3 (l3) #增(三种方法) 1、append:在后面追加 li =[ , li =['alex','wusir','egon','女神','taibai','日天'] ? ?2、insert#插入 =[ , taibai li.insert(4, 3、extend: #迭代的添加到最后面 li =[[详细]
-
Python:数据类型
所属栏目:[Python] 日期:2020-12-17 热度:189
1、数据类型int :如1、2、4等, 用于计算 bool: True,False,用户判断 str: 储存少量数据,进行操作。如:'fdasklfjfladfl','而而噩噩','1234' list:储存大量数据。用中括号引起来。['哈哈',1324,34455,[1,2,3]],可以储存的数据很多。tupe元组:只读[详细]
-
?Python:运算与循环
所属栏目:[Python] 日期:2020-12-17 热度:194
name = input( =input( =input( =input( = % (msg) div class="cnblogs_code" name = input( = input( = input( = %(name,age,height) name = input( = input( = input( = %(name,age,height) 2、while else与其它语言else 一般只与if 搭配不同,在Pytho[详细]
-
?Python:计算机基础知识
所属栏目:[Python] 日期:2020-12-17 热度:66
cpu:相当于人的大脑,用于计算。 内存:储存数据,运行速度快,成本高,断电数据消失。 硬盘 :固态硬盘(快)、机械硬盘(有指针)。储存数据,需要长期保持数据,重要文件 打开qq过程:点击-硬盘-调用数据到内存-寄存器-cpu-传输数据到显示器。 操作系统[详细]
-
代码
所属栏目:[Python] 日期:2020-12-16 热度:143
从百度搜索,净是csdn下载的,现在csdn下载弄的很恶心,垄断并且只想赚钱了,不想使用, 去github上找到了。 https://github.com/PacktPublishing/Learning-Data-Mining-with-Python[详细]
-
python3根据地址批量获取百度地图经纬度
所属栏目:[Python] 日期:2020-12-16 热度:91
python3代码如下:[详细]
-
python 字符串转字节数组
所属栏目:[Python] 日期:2020-12-16 热度:133
场景: java加解密和python加解密互转的时候,因一些非显示字符无法确认两者是否一致,故需要打出他们的十六进制字节数组进行比较 1.python代码实现 str='123';print str.encode('hex')结果显示:313233 2. java实现 String str="123" = ( i=0;i =([详细]
-
No module named Crypto--转
所属栏目:[Python] 日期:2020-12-16 热度:172
https://blog.csdn.net/lacoucou/article/details/53152122 1.pip install pycropt 这中办法经常会报错: 似乎也很麻烦。 2.使用编译好的安装包。下载地址: 根据自己的版本现在对应的安装即可。 然而,安装完,或许并没有什么卵用,使用依旧报错: 经过苦苦[详细]
-
安装带 Python 支持的 uWSGI
所属栏目:[Python] 日期:2020-12-16 热度:54
http://uwsgi-docs-cn.readthedocs.io/zh_CN/latest/WSGIquickstart.html 这个快速入门指南将会向你展示如何部署简单的 WSGI 应用和普通 web 框架。 Python 在这里特指 CPython,如果你想用 PyPy 你需要使用专门的插件:?,Jython 的支持正在开发中。 安装带 P[详细]
-
Anaconda(miniconda)安装及使用--转
所属栏目:[Python] 日期:2020-12-16 热度:199
https://www.waitalone.cn/anaconda-install-error.html div id="single_card" div class="post_hd" div id="bdshare" class="bdshare_t bdsharebuttonbox bds_tools get-codes-bdshare stb_share_buttons stb_group"? div class="post_dw"? div class="post[详细]
-
关于python2.7的md5加密遇到的问题(TypeError: Unicode-objects
所属栏目:[Python] 日期:2020-12-16 热度:144
https://blog.csdn.net/u012087740/article/details/48439559 span style="color: #0000ff;"def span style="color: #000000;" md5s(): m =span style="color: #000000;"hashlib.md5() strs =sys.argv[1span style="color: #000000;"] m.update(strs.encode([详细]
-
爬虫提取非结构化数据
所属栏目:[Python] 日期:2020-12-16 热度:52
pdf:pdfBox解析pdf文档 word:poi rtf:rtfconverter4j excel:jxl,poi,数据库访问jsqlparser powerpoint:poi 图片:javax.imageio.Imageio ? ? ? ? 二值化:[详细]
-
python2 'str' object has no attribute &#
所属栏目:[Python] 日期:2020-12-16 热度:189
div class="cnblogs_code" .decode( ) 上述代码,报错: 'str' object has no attribute 'decode' 查找原因: https://stackoverflow.com/questions/29030725/str-object-has-no-attribute-decode You cannot decode string objects; they are? already ?dec[详细]
-
1 概述
所属栏目:[Python] 日期:2020-12-16 热度:126
http://blog.51cto.com/xpleaf/2093952 1 概述 在不用爬虫框架的情况,经过多方学习,尝试实现了一个分布式爬虫系统,并且可以将数据保存到不同地方,类似MySQL、HBase等。 基于面向接口的编码思想来开发,因此这个系统具有一定的扩展性,有兴趣的朋友直接看[详细]
-
Windows键盘驱动结构与消息机制--转
所属栏目:[Python] 日期:2020-12-16 热度:97
https://www.douban.com/note/318793892/ 本文主要介绍按键消息是如何传递到窗口并转化为具体的按键消息的。Windows系统是事件驱动的多任务系统,其中按键和鼠标是主要的事件。按键是由键盘驱动获得并转换,然后广播给各个窗口。整个架构的核心是csrss.exe这[详细]
-
Java. How to use headless browsers for crawling web and scra
所属栏目:[Python] 日期:2020-12-16 热度:178
https://www.linkedin.com/pulse/java-how-use-headless-browsers-crawling-web-scraping-data-taluyev/ Did you ever think to implement software to scrape data from web pages? I guess everyone could think about crawling web. The simplest way to[详细]
-
java.net.URISyntaxException: Illegal character in query
所属栏目:[Python] 日期:2020-12-16 热度:89
java使用httpclient爬取一个网站的时候,请求:String url3="http://sh.58.com/ershoufang/33562546149042x.shtml?amp;params=esfjxpclranxuanctrAB^descamp;fzbref=0amp;entinfo=33562546149042_0amp;cookie=|||c5/nn1jLReK730pAPL8MAg==amp;psid=108219688[详细]
-
selenium打开chrome浏览器代码
所属栏目:[Python] 日期:2020-12-16 热度:199
div class="cnblogs_code" selenium chromedriver = span style="color: #800000;"" span style="color: #800000;"C:Program Files (x86)GoogleChromeApplicationchrome.exe span style="color: #800000;"" span style="color: #000000;" os.environ[ s[详细]
-
深入理解Python字符编码--转
所属栏目:[Python] 日期:2020-12-16 热度:193
http://blog.51cto.com/9478652/2057896 不论你是有着多年经验的 Python 老司机还是刚入门 Python 不久,你一定遇到过UnicodeEncodeError、UnicodeDecodeError 错误,每当遇到错误我们就拿着 encode、decode 函数翻来覆去的转换,有时试着试着问题就解决了,[详细]
-
History of the browser user-agent string--转
所属栏目:[Python] 日期:2020-12-16 热度:80
https://webaim.org/blog/user-agent-string-history/ In the beginning there was?,and Mosaic called itself? NCSA_Mosaic/2.0 (Windows 3.1) ,and Mosaic displayed pictures along with text,and there was much rejoicing. ,being short for “Mosaic K[详细]
-
从 Zero 到 Hero ,一文掌握 Python--转
所属栏目:[Python] 日期:2020-12-16 热度:192
https://www.oschina.net/translate/learning-python-from-zero-to-hero 第一个问题,什么是 Python ?根据 Python 之父 Guido van Rossum 的话,Python 是: 一种高级程序语言,其核心设计哲学是代码可读性和语法,能够让程序员用很少的代码来表达自己的想[详细]
-
1. Grabs All Hyperlinks
所属栏目:[Python] 日期:2020-12-16 热度:124
原文地址:http://www.mkyong.com/java/jsoup-html-parser-hello-world-examples/ ,a HTML parser,its “jquery-like” and “regex” selector syntax is very easy to use and flexible enough to get whatever you want. Below are three examples to sho[详细]
