使用方法:nth_element(start, start+n, end) 使第n大元素处于第n位置(从0开始,其位置是下标为n的元素),并且比这个元素小的元素都排在这个元素之前,比这个元素大的元素都排在这个元素之后,但不能保证他们是有序的。 #include <algorithm> #includ ...
分类:
其他好文 时间:
2019-01-24 22:59:13
阅读次数:
239
Rendezvous Hashing Rendezvous or highest random weight (HRW) hashing is an algorithm that allows clients to achieve distributed agreement on a set of ...
分类:
其他好文 时间:
2019-01-24 20:06:48
阅读次数:
171
1008 Elevator (20 分) The highest building in our city has only one elevator. A request list is made up with N positive numbers. The numbers denote at ...
分类:
其他好文 时间:
2019-01-24 15:37:21
阅读次数:
144
今天案例的灵感来自于下图: 这次没有仿着做这个案例,我只是做了一下翻牌效果,成品如下 html代码 css样式 backface visibility不能放在div:nth child(2)反面中,需放在div中,不然转的时候会看到正面 ...
分类:
其他好文 时间:
2019-01-21 13:48:01
阅读次数:
153
要求:1、程序运行时,让用户输入工资大小。2、列出当所有产品列表清单。3、让用户输入需要购买的产品编号。4、结束程序时,打印购买明细与剩下余额。#AuthorKangshopping_list=[(‘Iphone‘,5000),(‘MacBook‘,9000),(‘HuweiP20‘,9999)]shopping_car=[]salary=int(input(‘请输入你的工资:‘))whileTr
分类:
编程语言 时间:
2019-01-17 23:44:20
阅读次数:
252
import json,timeuserinfo={"lanfei": { "passwd":"lanfei", "salary":3000, "buy_commodity":{ "time":None, "commodity_name":None, "price":None,}, "shoppin ...
分类:
编程语言 时间:
2019-01-14 18:00:21
阅读次数:
106
# app01.models.py from django.db import models class Emp(models.Model): name = models.CharField(max_length=32) age = models.IntegerField() salary = mo... ...
分类:
其他好文 时间:
2019-01-14 01:05:09
阅读次数:
202
视图 create [or replace]#如果存在就替换 view 视图名字(#可防止标题栏字段) as (select name,salary from em); alter view 视图名字 as (select name,salary from em); 等价于上面的 or replac ...
分类:
其他好文 时间:
2019-01-13 19:02:02
阅读次数:
163
import pickle import numpy as np def save_obj(obj, name): with open(name + '.pkl', 'wb') as f: pickle.dump(obj, f, pickle.HIGHEST_PROTOCOL) def load_o... ...
分类:
编程语言 时间:
2019-01-10 20:29:40
阅读次数:
958
选择器补充 筛选选择器 伪类选择器 :XX() :eq() 根据索引找元素,从0开始 :first() 第一个子元素 :last()最后一个子元素 :nth-child(index) 根据序号找元素,从1开始 属性选择器 $('input:radio') ? > $('input[type = ra ...
分类:
Web程序 时间:
2019-01-10 10:57:11
阅读次数:
196