上一页 1 ··· 25 26 27 28 29 30 31 32 33 ··· 36 下一页
1.TheServerSide这是一个老牌的IT信息网站,从名称上你就能看出,它是关注服务器端编程的,以Java和Java周边信息为主,不过最近它也有向客户端和微软产品 扩展的趋势。这个网站最初是以免费发放《Mastering Enterprise JavaBeans》这本电子书出名的,现在这本书已经更新到了ELB 3.0版,你现在仍然可以从网站上免费下载这本书。这个网站的内容包括IT新闻咨询,专家评论,专家访谈视频,会议视频等。2.infoqinfoq上一个重点就是敏捷开发,内容很丰富,而且这个网站还提供中文版,但可能是翻译耗时的原因,中文内容总是比英文内容滞后几天。3.Digg 的科技频道 Read More
posted @ 2012-12-21 16:31 godjob Views(300) Comments(0) Diggs(0) Edit
The Broken PedometerThe ProblemA marathon runner uses a pedometer with which he is having problems. In the pedometer the symbols are represented by seven segments (or LEDs):But the pedometer does not work properly (possibly the sweat affected the batteries) and only some of the LEDs are active. The Read More
posted @ 2012-12-01 22:48 godjob Views(422) Comments(0) Diggs(0) Edit
学习linux不要死记硬背,更不要全部学会,够用就行,下面直接看例子,学习的最好方法就是看例子学习:$find ~ -name "*.txt" -print #在$HOME中查.txt文件并显示$find . -name "*.txt" -print$find . -name "[A-Z]*" -print #查以大写字母开头的文件$find /etc -name "host*" -print #查以host开头的文件$find . -name "[a-z][a-z][0–9][0–9].txt" Read More
posted @ 2012-11-27 16:00 godjob Views(177) Comments(0) Diggs(0) Edit
import sqlite3#10003[:1]{:2}{2}db = sqlite3.connect(r'c:\imageDB.db')cur=db.cursor();db.commit();try:cur.execute('insert into cet_t values(?,?)',('title2.jpg',sqlite3.Binary('123'),))except sqlite3.IntegrityError:import sysprint sys.exc_info()[0],sys.exc_info()[1]prin Read More
posted @ 2012-11-25 23:38 godjob Views(438) Comments(0) Diggs(0) Edit
# -*- coding: utf-8 -*-"""Created on Sun Nov 25 15:56:01 2012@author: l"""import sqlite3db = sqlite3.connect(r'c:\imageDB.db')#fp=open(r'c:\title.jpg','rb')#data=fp.read();#fp.close()cur=db.cursor()#cur.execute('insert into cet_t values(" Read More
posted @ 2012-11-25 22:30 godjob Views(788) Comments(0) Diggs(0) Edit
import sqlite3def sqlite_basic(): # Connect to db conn = sqlite3.connect('test.db') # create cursor c = conn.cursor() # Create table c.execute(''' create table if not exists stocks (date text, trans text, symbol text, qty real, price real) ... Read More
posted @ 2012-11-25 22:15 godjob Views(1984) Comments(0) Diggs(0) Edit
遍历存元组的列表进行操作一堆xy坐标,找出x,y的左上角与右下角[python] view plaincopyprint?max_t=reduce(lambdax,y:(max(x[0],y[0]),max(x[1],y[1])),l)p;min_t=reduce(lambdax,y:(min(x[0],y[0]),min(x[1],y[1])),l)用zipfile写压缩包[python] view plaincopyprint?f=zipfile.ZipFile("testzip.zip","w",zipfile.ZIP_DEFLATED)f.wri Read More
posted @ 2012-11-25 21:50 godjob Views(288) Comments(0) Diggs(0) Edit
#include <stdio.h>#include <sqlite3.h>#include <stdlib.h>static sqlite3 *db=NULL;static sqlite3_stmt *stmt=NULL;FILE *fp;long filesize=0;char *fflie;int main(int argc, char *argv[]){ int rc,i,j; rc = sqlite3_open("dishes.db", &db); rc = sqlite3_prepare(db, "updat Read More
posted @ 2012-11-25 20:58 godjob Views(1277) Comments(0) Diggs(0) Edit
python中对文件、文件夹的操作需要涉及到os模块和shutil模块。创建文件:1) os.mknod("test.txt") 创建空文件2)open("test.txt",w)直接打开一个文件,如果文件不存在则创建文件创建目录:os.mkdir("file")创建目录复制文件:shutil.copyfile("oldfile","newfile")oldfile和newfile都只能是文件shutil.copy("oldfile","newfile") Read More
posted @ 2012-11-25 00:16 godjob Views(299) Comments(0) Diggs(0) Edit
掌握文本文件读写的方法了解二进制文件的读写方法C++文件流:fstream // 文件流ifstream // 输入文件流ofstream // 输出文件流//创建一个文本文件并写入信息//同向屏幕上输出信息一样将信息输出至文件#include<iomanip.h>#include<fstream.h>void main(){ ofstream f1("d:\\me.txt"); //打开文件用于写,若文件不存在就创建它 if(!f1)return; //打开文件失败则结束运行 f1<<setw(20)<<"姓名:& Read More
posted @ 2012-11-23 22:57 godjob Views(317) Comments(0) Diggs(0) Edit
上一页 1 ··· 25 26 27 28 29 30 31 32 33 ··· 36 下一页