正确的程序如下所示:
#! /usr/bin/env python
# -*- coding: utf-8 -*-
from VideoCapture import Device
import time
import sys,pygame
pygame.init()
size = width,height = 620,485
speed = [2,2]
blac...
分类:
编程语言 时间:
2014-06-16 23:10:24
阅读次数:
568
1 引用XML文件
2 使用XMLReader解析文本字符串
3 使用XMLReader方法读取XML数据
具体代码实现如下:
//初始化一个XML字符串
String xmlString =
@"
The Autobiography of Benjamin...
分类:
其他好文 时间:
2014-06-16 22:59:13
阅读次数:
142
题目
Given a string containing just the characters '(' and ')',
find the length of the longest valid (well-formed) parentheses substring.
For "(()", the longest valid parentheses substring...
分类:
其他好文 时间:
2014-06-16 22:41:41
阅读次数:
267
一、基本类型
1.string类型是值引用的,简单地说就是把String A作为参数传出去到String B,不管B的值如何改变,A是不会改变的,除非手动改变A的值。
2.在看翻译过来的中文版本时,发现一个问题,说数组是存放相同类型的的数据的一个集合,其数据类型也可通过自动推断方式获取,可不必声明,但在实际code过程中,发现一个问题如下:
//不加类型声明,可以在初始化时在数组中添加Str...
分类:
其他好文 时间:
2014-06-16 21:48:20
阅读次数:
233
/*
ID:kevin_s1
PROG:holstein
LANG:C++
*/第八组数据跪了,半天都不出结果
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
using namespace std;
#define MA...
分类:
其他好文 时间:
2014-06-16 20:59:10
阅读次数:
268
/*
ID:kevin_s1
PROG:holstein
LANG:C++
*/
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
using namespace std;
#define MAXV 26
#define M...
分类:
其他好文 时间:
2014-06-16 20:05:47
阅读次数:
166
DECLARE @TABLE_NAME VARCHAR(200) SET @TABLE_NAME = 'myFunction' --表名
DECLARE @TABLE_CONDITION VARCHAR(200) SET @TABLE_CONDITION = 'where Application=''0303'' AND FunctionType=''功能''' --条件
DECL...
分类:
数据库 时间:
2014-06-16 19:38:05
阅读次数:
267
Map是c++的一个标准容器,她提供了很好一对一的关系,在一些程序中建立一个map可以起到事半功倍的效果,总结了一些map基本简单实用的操作!
1. map最基本的构造函数;
mapmapstring; mapmapint;
mapmapstring; mapmapchar;
mapmapchar; m...
分类:
其他好文 时间:
2014-06-16 19:35:02
阅读次数:
187
题目
Implement strStr().
Returns a pointer to the first occurrence of needle in haystack, or null if needle is not part of haystack.
方法
只需要遍历一遍即可。
public String strStr(String...
分类:
其他好文 时间:
2014-06-16 19:07:08
阅读次数:
188
'''
Created on 2014年6月15日
@author: Yang
'''
import socket
import datetime
# 初始化socket
s = socket.socket()
# 获取主机名, 也可以使用localhost
# host = socket.gethostname()
host = "localhost"
# 默认的http协议端口号
port...
分类:
编程语言 时间:
2014-06-16 14:17:33
阅读次数:
349