首页 > 其他
判断给到的年份是否为闰年
#写一个程序,判断给到的年份是否为闰年 temp=input('请输入一个年份:') while temp.isdigit()==False: temp=input('该吃药了吧,重新输入:') year=int(temp) if ((year%4==0) and (year%100!=0)) or ...
分类:其他   时间:2017-01-31 14:23:04    收藏:0  评论:0  赞:0  阅读:223
How TCP clients and servers communicate using the TCP sockets interface
wTCP客户端和服务器是如何通过TCP套接字接口进行通讯的。服务器距离、负载,网络拥堵。 HTTP The Definitive Guide We begin with the web server waiting for a connection (Figure 4-6, S4). The cli ...
分类:其他   时间:2017-01-31 14:22:51    收藏:0  评论:0  赞:0  阅读:241
for/range/break/continue
#for智能循环 members=['武林至尊','宝刀屠龙','号令天下','莫敢不从'] for every in members: print(every,len(every)) 武林至尊 4 宝刀屠龙 4 号令天下 4 莫敢不从 4 武林至尊 4 宝刀屠龙 4 号令天下 4 莫敢不从 4 # ...
分类:其他   时间:2017-01-31 14:22:37    收藏:0  评论:0  赞:0  阅读:214
OpenStack介绍(一)
官方网站:http://www.openstack.org/ 介绍 OpenStack是一个由NASA(美国国家航空航天局)和Rackspace合作研发并发起的,以Apache许可证授权的自由软件和开放源代码项目。 OpenStack是一个开源的云计算管理平台项目,由几个主要的组件组合起来完成具体工 ...
分类:其他   时间:2017-01-31 13:43:24    收藏:0  评论:0  赞:0  阅读:260
Leetcode 346. Moving Average from Data Stream
Given a stream of integers and a window size, calculate the moving average of all integers in the sliding window. For example, 思路:本题比较简单,在__init__的时候, ...
分类:其他   时间:2017-01-31 13:42:41    收藏:0  评论:0  赞:0  阅读:355
POJ3335 POJ3130 [半平面交]
终于写出自己的半平面交模板了....... 加入交点的地方用了直线线段相交判定 两个题一样,只不过一个顺时针一个逆时针(给出一个多边形的两种方式啦),反正那个CutPolygon是切掉左面 ...
分类:其他   时间:2017-01-31 13:42:08    收藏:0  评论:0  赞:0  阅读:205
219. Contains Duplicate II
Given an array of integers and an integer k, find out whether there are two distinct indices i and j in the array such that nums[i] = nums[j]and the a ...
分类:其他   时间:2017-01-31 13:41:38    收藏:0  评论:0  赞:0  阅读:318
TOJ-1321 The Brick Stops Here
You have been hired by several clients of a factory that manufactures brass bricks. Brass is an alloy of copper and zinc; each brick weighs 1000 grams ...
分类:其他   时间:2017-01-31 13:40:22    收藏:0  评论:0  赞:0  阅读:225
217. Contains Duplicate
Given an array of integers, find if the array contains any duplicates. Your function should return true if any value appears at least twice in the arr ...
分类:其他   时间:2017-01-31 13:39:46    收藏:0  评论:0  赞:0  阅读:225
北漂职业生涯中心酸而又收获颇丰的一年
每年的年初年末的惯例,只不过今年把这篇文章搬家到这里来了。2016的总结2015年底跳槽到现在的公司,从那时开始便经历了一段从未经历的职业生涯。整个过程中多次想放弃,由于种种原因又坚持了下来。现在站在...
分类:其他   时间:2017-01-31 12:58:57    收藏:0  评论:0  赞:0  阅读:224
Pandas 秘籍
Pandas 秘籍 原文:Pandas Cookbook 译者:飞龙 协议:CC BY-NC-SA 4.0 第一章import pandas as pd pd.set_opti...
分类:其他   时间:2017-01-31 12:58:34    收藏:0  评论:0  赞:0  阅读:704
The CHAR and VARCHAR Types
【The CHAR and VARCHAR Types】 The CHAR and VARCHAR types are declared with a length that indicates the maximum number of characters you want to store. ...
分类:其他   时间:2017-01-31 12:57:22    收藏:0  评论:0  赞:0  阅读:246
PE病毒初探——向exe注入代码
PE文件其实就是Windows可执行文件,关于它的一些简要介绍摘自百度: PE文件被称为可移植的执行体是Portable Execute的全称,常见的EXE、DLL、OCX、SYS、COM都是PE文件,PE文件是微软Windows操作系统上的程序文件(可能是间接被执行,如DLL)。 http://b ...
分类:其他   时间:2017-01-31 12:57:08    收藏:0  评论:0  赞:0  阅读:282
POJ 1064 Cable master
Cable master Time Limit: 1000MS Memory Limit: 10000K Total Submissions: 41348 Accepted: 8873 Description Inhabitants of the Wonderland have decided to ...
分类:其他   时间:2017-01-31 12:56:53    收藏:0  评论:0  赞:0  阅读:205
sublime 使用笔记
安装sublime #https://www.sublimetext.com/3激活码 激活插件机制 ctrl + `#输入下面网址相应版本#https://packagecontrol.io/installation设置安装皮肤,字体 #打开文件,设置相应文件的皮肤和字体,例如设置php皮肤和字体 ...
分类:其他   时间:2017-01-31 12:56:23    收藏:0  评论:0  赞:0  阅读:269
TCP/IP协议栈(三)—— 向下的报文处理
应用程序连接服务器时,目的地套接字地址(端口号和IP地址)以参数形式传递给系统调用connect(tcp_v4_connect())。下面逐步介绍初始化该连接 前面阐述啦首次连接设置的处理过程,在此过程缓存了一些重要信息,如路由、设备、APR等。下面将介绍TCP套接着写数据。 查找与套接字描述符相对 ...
分类:其他   时间:2017-01-31 12:56:12    收藏:0  评论:0  赞:0  阅读:364
309. Best Time to Buy and Sell Stock with Cooldown
Say you have an array for which the ith element is the price of a given stock on day i. Design an algorithm to find the maximum profit. You may comple ...
分类:其他   时间:2017-01-31 12:55:34    收藏:0  评论:0  赞:0  阅读:173
UVa 1519 Dictionary Size
方法:Trie 看了题解,有两种做法,大致是相通的。这道题重点在于如何判重。 建立两个trie,取名prefix 和 suffix。把所有string插入第一个trie,每个节点就代表一种prefix。同理,把所有string反转之后插入第二个trie,每个节点就代表一个suffix。如果没有重复的 ...
分类:其他   时间:2017-01-31 12:54:00    收藏:0  评论:0  赞:0  阅读:314
[BZOJ3772]精神污染
[BZOJ3772]精神污染 试题描述 兵库县位于日本列岛的中央位置,北临日本海,南面濑户内海直通太平洋,中央部位是森林和山地,与拥有关西机场的大阪府比邻而居,是关西地区面积最大的县,是集经济和文化于一体的一大地区,是日本西部门户,海陆空交通设施发达。濑户内海沿岸气候温暖,多晴天,有日本少见的贸易良 ...
分类:其他   时间:2017-01-31 12:53:31    收藏:0  评论:0  赞:0  阅读:210
Codeforces Round #381 (Div. 2)
A题,虽然是水题,但是也需要仔细。代码如下: 1 #include <stdio.h> 2 #include <algorithm> 3 #include <string.h> 4 #include <vector> 5 #include <iostream> 6 using namespace s ...
分类:其他   时间:2017-01-31 12:52:47    收藏:0  评论:0  赞:0  阅读:186
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!