Click here to Skip to main content
15,906,081 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
QuestionHow to speed up copy of .txt files into arrays? Pin
Arris745-Apr-07 5:25
Arris745-Apr-07 5:25 
AnswerRe: How to speed up copy of .txt files into arrays? Pin
led mike5-Apr-07 5:32
led mike5-Apr-07 5:32 
AnswerRe: How to speed up copy of .txt files into arrays? Pin
Arris745-Apr-07 5:55
Arris745-Apr-07 5:55 
AnswerRe: How to speed up copy of .txt files into arrays? Pin
David Crow5-Apr-07 6:01
David Crow5-Apr-07 6:01 
GeneralRe: How to speed up copy of .txt files into arrays? Pin
Arris745-Apr-07 6:20
Arris745-Apr-07 6:20 
GeneralRe: How to speed up copy of .txt files into arrays? Pin
led mike5-Apr-07 6:28
led mike5-Apr-07 6:28 
GeneralRe: How to speed up copy of .txt files into arrays? Pin
Arris745-Apr-07 7:17
Arris745-Apr-07 7:17 
GeneralRe: How to speed up copy of .txt files into arrays? Pin
malaugh5-Apr-07 10:55
malaugh5-Apr-07 10:55 
Are the dates in order?

If the file starts with the earliest date and finishes with the latest date, then use the following method:

1) Fseek to the middle of the file
2) If the data is larger fseek to one quter of the way through the file, if smaller, fseek to 3 quarters of the way though the file.
3) Repeat.

Like guessing a number, if you ask someone select a number between 0 and 15, the quickest way to find the number is to ask,
Is it less than 8
If yes then ask is it less than 4
If no than ask is it less than 6

I'm sure you get the idea. Its a common technique.




GeneralRe: How to speed up copy of .txt files into arrays? Pin
Arris745-Apr-07 11:14
Arris745-Apr-07 11:14 
GeneralRe: How to speed up copy of .txt files into arrays? Pin
David Crow5-Apr-07 6:32
David Crow5-Apr-07 6:32 
GeneralRe: How to speed up copy of .txt files into arrays? Pin
Arris745-Apr-07 7:19
Arris745-Apr-07 7:19 
GeneralRe: How to speed up copy of .txt files into arrays? Pin
PJ Arends5-Apr-07 8:00
professionalPJ Arends5-Apr-07 8:00 
GeneralRe: How to speed up copy of .txt files into arrays? Pin
David Crow5-Apr-07 8:15
David Crow5-Apr-07 8:15 
GeneralRe: How to speed up copy of .txt files into arrays? Pin
led mike5-Apr-07 8:54
led mike5-Apr-07 8:54 
GeneralRe: How to speed up copy of .txt files into arrays? Pin
Arris745-Apr-07 9:20
Arris745-Apr-07 9:20 
GeneralRe: How to speed up copy of .txt files into arrays? Pin
Arris745-Apr-07 9:33
Arris745-Apr-07 9:33 
QuestionSCSI_PASS_THROUGH_DIRECT problems Pin
FoxholeWilly5-Apr-07 5:07
FoxholeWilly5-Apr-07 5:07 
QuestionWMI Pin
saisp5-Apr-07 4:48
saisp5-Apr-07 4:48 
QuestionRe: WMI Pin
David Crow5-Apr-07 6:05
David Crow5-Apr-07 6:05 
AnswerRe: WMI Pin
saisp5-Apr-07 7:04
saisp5-Apr-07 7:04 
GeneralRe: WMI Pin
David Crow5-Apr-07 7:19
David Crow5-Apr-07 7:19 
GeneralRe: WMI Pin
saisp5-Apr-07 7:51
saisp5-Apr-07 7:51 
GeneralRe: WMI Pin
David Crow5-Apr-07 8:03
David Crow5-Apr-07 8:03 
GeneralRe: WMI Pin
saisp5-Apr-07 8:11
saisp5-Apr-07 8:11 
GeneralRe: WMI Pin
David Crow5-Apr-07 8:17
David Crow5-Apr-07 8:17 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.