阅读背景:

查找字节数组数组是否包含另一个字节数组的最快方法是什么?

来源:互联网 

I have some code that is really slow. I knew it would be and now it is. Basically, I am reading files from a bunch of directories. The file names change but the data does not. To determine if I have read the file, I am hashing it's bytes and comparing that to a list of hashes of already processed files. There are about 1000 files in each directory, and figuring out what's new in each directory takes a good minute or so (and then the processing starts). Here's the basic code:I have some code that is really slow. I knew it




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: