Tag Archives: searching

基于windows线程的并行线性查找

#include #include #include #include typedef struct{ int * A; int num; int key; int threadID; } sParam; bool Done = FALSE; #define NUM_THREADS 4 void linearSearch(int * A, int s, int e, int key, DWORD *position) { int i; for … Continue reading

Leave a Comment

Filed under C++, 技术

二进制文件二分查找算法

package com.xxx.xxx.query.version2; import java.io.File; import java.io.IOException; import java.io.RandomAccessFile; import java.text.DateFormat; import java.text.SimpleDateFormat; import java.util.Date; import java.util.List; import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; import com.xxx.xxx.decode.MetaData; import com.xxx.xxx.utils.DateFormatUtil; public abstract class DataReader { protected static Log log = LogFactory.getLog(DataReader.class); protected static final int BUF_SIZE … Continue reading

Leave a Comment

Filed under C++, 技术