#1 gFile = open('g.txt',mode='r',encoding='utf-8') gText = gFile.read() gFile.close() print(gText) #2 replaceList = [',','.',"'",'\n'] for c in replac... ...
分类:
其他好文 时间:
2018-06-20 22:45:03
阅读次数:
262
#1. loveFile = open('love.txt',mode='r',encoding='utf-8') loveText = loveFile.read() loveFile.close() print(loveText) #2. replaceList = [',','.',"'",'... ...
分类:
其他好文 时间:
2018-06-20 22:43:26
阅读次数:
209
#1. SummertimeSadnessFile = open('SummertimeSadness.txt',mode="r",encoding='utf-8') SummertimeSadnessText = SummertimeSadnessFile.read() SummertimeSad... ...
分类:
其他好文 时间:
2018-06-20 22:36:35
阅读次数:
207
#1. theFile = open('the.txt',mode='r',encoding='utf-8') theText = theFile.read() # 从文件里读出全部文本,字符串 theFile.close() print(theText) #2. replaceList = [',... ...
分类:
其他好文 时间:
2018-06-20 22:35:43
阅读次数:
190
//11-7 #include using namespace std; int main() { ios_base::fmtflags original_flags=cout.flags(); // flag指针?指向开头? cout #include #include using namespa... ...
分类:
其他好文 时间:
2018-06-20 22:31:04
阅读次数:
165
qFile = open("q.txt",mode="r",encoding='utf-8') qText = qFile.read() qFile.close() print(qText) replaceList = [',','.',"'",'\n'] for c in replaceList:... ...
分类:
其他好文 时间:
2018-06-20 22:30:47
阅读次数:
146
#!/usr/bin/perlprint "TESTLIST File Name: @ARGV\n";my $testlist = $ARGV[0]; open(RD_FILE, "$testlist");@all_cases = <RD_FILE>; ##TODO add your command ...
分类:
其他好文 时间:
2018-06-20 21:24:25
阅读次数:
152
#!/usr/bin/perl use File::Basename; my $result_dir = $ARGV[0]; my $result_testlog_dir = "$result_dir/testlog"; opendir DIR, $result_testlog_dir; my $r ...
分类:
其他好文 时间:
2018-06-20 21:22:20
阅读次数:
156
1.单一职责原则(Single Responsibility Principle, SRP):一个类只负责一个功能领域中的相应职责,或者可以定义为:就一个类而言,应该只有一个引起它变化的原因。 2.开闭原则(Open-Closed Principle, OCP):一个软件实体应当对扩展开放,对修改关 ...
分类:
其他好文 时间:
2018-06-20 21:00:34
阅读次数:
177
前言 Linux系统中可以设置关于资源的使用限制,比如:进程数量,文件句柄数,连接数等等。 在日常的工作中应该遇到过: bash: fork: retry: Resource temporarily unavailable 或者 too many open files 这些类似的操作错误,前者是由于 ...
分类:
系统相关 时间:
2018-06-20 19:05:24
阅读次数:
258