Manhattan Wiring
Time Limit: 5000MS
Memory Limit: 65536K
Total Submissions: 1482
Accepted: 869
Description
There is a rectangular area containing n × m cells. Two...
分类:
其他好文 时间:
2014-07-22 23:05:35
阅读次数:
211
WSGI 是Web Services Gateway Interface的缩写. 如果想深入了解,可以阅读 PEP
333 文档,包含有任何你想要的:)community errata, .这篇文章将手把手教你写一个简单的WSGI例子。
注意:我用的Python版本是.2.7.x.
最经典,最简答的WSGI样当属 Hello
World app.
咱们将要用到 v...
分类:
其他好文 时间:
2014-07-22 23:03:53
阅读次数:
407
在Python中内部所有编码都是Unicode,Unicode属于中转码,一般来说,是先把乱码转化为中转码,再转化为我
们需要的编码,转换过程为decode -> unicode -> encode。
#coding:utf-8
#-*- coding:utf-8 -*-
import sys
print sys.getdefaultencoding()
print '中国'
f =...
分类:
编程语言 时间:
2014-07-22 23:03:34
阅读次数:
368
Matrix
Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)
Total Submission(s): 1332 Accepted Submission(s): 740
Problem Description
Yifenfei very like p...
分类:
其他好文 时间:
2014-07-22 23:03:13
阅读次数:
228
time_t SystemTimeToTime_t( const SYSTEMTIME& st )
{
tm temptm = {st.wSecond,
st.wMinute,
st.wHour,
st.wDay,
st.wMonth - 1,
st.wYear - 1900,
st...
分类:
其他好文 时间:
2014-07-22 23:02:34
阅读次数:
599
今天学习如何利用Python来解析XML文档。
给定一个XML文件,现在我们用Python来提取里面的内容。
11111111
120
15.0
Python代码:
import xml.etree.ElementTree as ET...
分类:
编程语言 时间:
2014-07-22 23:02:14
阅读次数:
322
Problem 1686 神龙的难题
Accept: 394 Submit: 1255
Time Limit: 1000 mSec Memory Limit : 32768 KB
Problem Description
这是个剑与魔法的世界.英雄和魔物同在,动荡和安定并存.但总的来说,库尔特王国是个安宁的国家,人民安居乐业,魔物也比较少.但是.总有一些...
分类:
其他好文 时间:
2014-07-22 23:02:12
阅读次数:
301
关于最大熵模型的介绍请看:http://www.cnblogs.com/hexinuaa/p/3353479.html
下面是GIS训练算法的python实现,代码不到100行。
from collections import defaultdict
import math
class MaxEnt(object):
def __ini...
分类:
其他好文 时间:
2014-04-30 22:46:39
阅读次数:
384
Crossing River
Time Limit: 1000MS
Memory Limit: 10000K
Total Submissions: 10212
Accepted: 3855
Description
A group of N people wishes to go across a river with only one...
分类:
其他好文 时间:
2014-04-30 22:21:38
阅读次数:
212