import socket client=socket.socket(socket.AF_INET,socket.SOCK_DGRAM) while True: msg=input('>>: ').strip() client.sendto(msg.encode('utf-8'),('127.0.0 ...
分类:
其他好文 时间:
2019-07-28 09:30:45
阅读次数:
112
while 1: username =input ('请输入你的注册账号:') userkey = input('请输入你的注册密码(只能是纯数字):') if userkey.isdigit(): with open('数据存储','r+',encoding='utf-8') as f: f.wr ...
分类:
其他好文 时间:
2019-07-27 23:57:30
阅读次数:
217
# 服务端必须满足至少三点: # 1. 绑定一个固定的ip和port # 2. 一直对外提供服务,稳定运行 # 3. 能够支持并发 import socketserver # 自定义类用来处理通信循环 class MyTCPhanler(socketserver.BaseRequestHandler ...
分类:
其他好文 时间:
2019-07-27 09:39:29
阅读次数:
97
from urllib.request import Request from urllib.request import urlopen from bs4 import BeautifulSoup url = "https://www.amazon.com/s?k=led+strip+lights ...
分类:
其他好文 时间:
2019-07-26 01:42:25
阅读次数:
82
# 链家新房爬虫 **今日目标** 爬取最新地区以及对应的房价 ```python import requests import re import csv class LianjiaSpider(object): def __init__(self): self.url='https://cq.l... ...
分类:
其他好文 时间:
2019-07-23 22:31:29
阅读次数:
158
扩展阅读 趣图:网上复制的代码,运行一下 趣图:程序员写代码专用辅助 趣图:后端工程师做 UI 的活 ...
分类:
其他好文 时间:
2019-07-22 15:19:59
阅读次数:
93
要发个新版本,结果发现,老是提示我“No iTunes Connect access for the team”,出现以下错误: 图1 错误提示: No accounts with iTunes connect access have been found for the team “***co., ...
分类:
移动开发 时间:
2019-07-20 17:16:31
阅读次数:
562
ServletRequest和HttpServletRequest的区别 HttpServletRequest和ServletRequest都是接口,HttpServletRequest继承自ServletRequest HttpServletRequest比ServletRequest多了一些针对 ...
分类:
编程语言 时间:
2019-07-20 14:33:55
阅读次数:
216
先说一下strip()函数 描述:python strip()只能用于移除string 开头或结尾的charts(默认情况下为'/n','/t','/r',' ') string.strip(chars=None,/),有返回值 string="hello,world"a=string.strip( ...
分类:
其他好文 时间:
2019-07-20 11:40:43
阅读次数:
75