1- strip()方法可以从字符串去除不想要的空白符(role, line_spoken) = each_line.split(":", 1)line_spoken = line_spoken.strip()2- print() BIF的file参数控制将数据发送/保存到哪里print(...) ...
分类:
编程语言 时间:
2014-06-28 23:07:59
阅读次数:
318
sketch.py 1 #--*-- coding:utf-8 --*-- 2 import pickle 3 import nester 4 man = [] 5 other = [] 6 try: 7 data = open ("datafile.txt") 8 9 for e...
分类:
编程语言 时间:
2014-06-28 23:02:43
阅读次数:
300
今天在上班期间花了点时间学习了一下微软的EntityFramework Code First技术,这篇文章只是简单的入门,不多废话,下面直入主题。一.首先添加一个解决方案,接着添加一个web网站,DataAccess类库(用于数据访问),Model类库(实体层),结构如下:二.安装EntityFra...
分类:
Web程序 时间:
2014-06-18 09:56:08
阅读次数:
242
自动化测试的分类Web UI 的自动化测试(一类:模拟真实用户操作[鼠标键盘],二类:模拟HTTP请求)Windows 窗体的UI自动化测试API测试(Web API,WCF Service)数据库测试(存储过程)接口测试单元测试性能测试自动化应具备的知识点:了解Javascript, CSS的知识...
分类:
其他好文 时间:
2014-06-18 09:15:25
阅读次数:
157
最近一段时间在学习PHP,买了《Head First P http:// HP&MySQL》中文版这本书,之前买过《Head First设计模式》,感觉这系列的书籍总体来说很不错。
HeadFirst 系列丛书的官网为:http://www.headfirstlabs.com/ , 有大概30本书,并且提供了每本书的代码下载,可以跟着书做做练习,不会的再看看源代码示例。
另外,学习P...
分类:
数据库 时间:
2014-06-18 07:03:08
阅读次数:
256
"个记录", "prev"=>"上一页", "next"=>"下一页", "first"=>"首 页", "last"=>"尾 页"); private $listNum=8; /* * $total * $listRows */ public function __constr...
分类:
其他好文 时间:
2014-06-17 23:36:02
阅读次数:
396
初识泛型算法
理解算法的最基本方法是了解他们是否读取元素、改变元素或是重排元素顺序!
只读算法
#include
#include
using namespace std;
//对vec中的元素求和,初值是0
int sum=accumulate(vec.cbegin(), vec.cend(), 0);
这里面第三个参数决定了函数使用哪个加法运算符以及返回值类型。
...
分类:
编程语言 时间:
2014-06-17 19:12:26
阅读次数:
261
??
First, a
dependency is a semantic relationship between two model elements in which a change to one element
(the independent one) may affect the semantics of the other element (the dependent on...
分类:
其他好文 时间:
2014-06-17 18:50:36
阅读次数:
182
??
Common Divisions
In modeling object-oriented systems, the world often gets divided in several ways.
First, there is the division of class and object. A class is an abstraction; an object is one ...
分类:
其他好文 时间:
2014-06-17 16:25:38
阅读次数:
322
复制容器(container)的元素至另一个容器本文地址: http://blog.csdn.net/caroline_wendyC++复制容器(container)元素, 可以使用标准库(STL)的copy()和copy_n()函数.函数样式: OutputIterator copy (InputIterator first, InputIterator last, OutputIterator...
分类:
编程语言 时间:
2014-06-17 16:06:13
阅读次数:
333