D:\1\下有很多txt文件
以下是txt文件中的内容
1.txt
VI,015, A,R,4,"RRE,01502,A,044,04"
VI,016, 71601,A,044,04"
BC,NS,1,1,L,1, 406.166, 406.166,28.53,U,6,33.80,-99999.99,3333,a
BC,NS,2,1,L,2, 98.633, 98.633,20.51,U,6,33.80,-99999.99,4444,c
BC,NS,3,1,L,3, 586.001, 586.001,28.42,U,6,34.80,-99999.99,5555,r
BC,NS,4,1,L,4, 586.001, 86.001,18.42,U,6,35.80,-99999.99,6666,g
2.txt
VI,015, A,R,4,"RRE,01502,A,044,04"
VI,016, 71601,A,044,04"
BC,NS,1,1,R,1, 406.166, 406.166,19.43,U,6,33.80,-99999.99,7777,ca
BC,NS,2,1,L,2, 98.633, 98.633,20.31,U,6,33.80,-99999.99,8888,cc
BC,NS,3,1,L,3, 586.001, 586.001,26.45,U,6,34.80,-99999.99,9999,rt
BC,NS,4,1,L,4, 586.001, 86.001,15.62,U,6,35.80,-99999.99,0000,b
等等很多文本文件
要做的是 查看带有BC开头(BC有很多行)的记录,第8个逗号之后的数字如果大于25则将 本行第13个和第14个逗号后的数字写入另一个文本文件中即可,
例如上两个可以写成如下:
3333,a
5555,r
9999,rt
非常感谢!!! |