Sitemap

Amicuk Programming Answers

Binary search in a text file.

-0001-11-30   Views:0

Advertisement

Is it possible to carry out binary search directly in the text file without passing the file data into a List data, in order to save RAM?If the file is sorted, and if you know what byte position each record begins at, then, yes, using RandomAccessFil

Is it possible to carry out binary search directly in the text file without passing the file data into a List data, in order to save RAM?

The replay answer
Advertisement
If the file is sorted, and if you know what byte position each record begins at, then, yes, using RandomAccessFile you can do this.
I don't know if it's really the best approach though. If the file's not all that big, or if the relevant parts of its content can be represented in more compact form, then sorting in memory will be simpler and quicker.

Go to See the other 3 answers

Binary search in a text file.

Category:DefaultRelease time:-0001-11-30Views:130

Is it possible to carry out binary search directly in the text file without passing the file data into a List data, in order to save RAM?If the file is sorted, and if you know what byte position each record begins at, then, yes, using RandomAccessFil[More]

[svn:osmf:] 11361: Adding a generic binary search utility ( updating project file).

Category:DefaultRelease time:-0001-11-30Views:130

Revision: 11361 Author:   [email protected] Date:     2009-11-02 05:21:35 -0800 (Mon, 02 Nov 2009) Log Message: Adding a generic binary search utility (updating project file). Modified Paths:     osmf/trunk/framework/MediaFramework/.flexLibProperties[More]

Write diadem search results to text file

Category:DefaultRelease time:2015-10-11Views:130

Is there a solution within DIAdem for exporting specific information from a search result into a text file? For example: I perform a search which returns all of the files, groups, and/or channels which I want to work with; now I would like to have, s[More]

Search word in text file

Category:DefaultRelease time:2015-10-11Views:130

Hello, someone can help me with code? How to search in text file any word and count how many it were repeated? For example test.txt: hi hola hey hi bye hoola hiAnd if I want to know how many times are repeated in test.txt word "Hi" program must[More]

Searching for a text file

Category:DefaultRelease time:-0001-11-30Views:130

hi i want to search for a file in the same folder as my project and read the contents of that file ... i know how to read from text file but i just need to know how i can search in the folder to look for a txt file called me.txt and open it for readi[More]

Need to search contents of text files on a windows network drive....

Category:DefaultRelease time:-0001-11-30Views:130

I am trying to search the content of a directory on a windows network drive for that contains .sas files (essentially text files) for a certain text string. Find does not seem to do this. Any ideas/suggestions? When I copy a file to my desktop I can[More]

Binary search in text files

Category:DefaultRelease time:2015-10-11Views:130

Hi all, I'm thinking about how to implement a binary sort to get,given a key, a value from a text file with a list of words in order. I saw randomaccessfile for j2se and I know that this work it's usually done by seek functions but how to do the seek[More]

Binary search in files

Category:DefaultRelease time:-0001-11-30Views:130

Is there a way of executa a binary search directlly over a file ? a java native way ?That would work best with a RandomAccessFile, since a binary search jumps back and forth looking at different places in the search space. And it would have to be a R[More]

Extract text file from a folder and read the content

Category:DefaultRelease time:2015-10-11Views:130

Hi I have "n" no.of text files saved in a folder with automatically generated naming convention which include DD/MM/YYYY and also some measurement output value. Eg: 1) Die_1_DUT_outputvalue_DD_MM_YYYY.txt     2) Die_1_DUT_outputvalue_DD_MM_YYYY_[More]

Find Change through external text file

Category:DefaultRelease time:2015-10-11Views:130

Hello folks I am bit pretty in InDesign scripting so could you please look into this. How can i change any particular text field in Indesign CS3 document from text file. I do have find change script but for each InDesign document specific text file i[More]

Reading in text file

Category:DefaultRelease time:2015-10-11Views:130

I have a text file that contains something like this: <setting name="ip_address" serializeAs="String">                 <value>239.0.0.1</value> I want to be able to search through the text file and based upon finding[More]

Hot
Hi all. We have 2 societies  0001  and 0002. In transaction S_ALR_87003642 or OB52 I want that user of society 0001 only can see posting periods of his society ( 0001 ) and the same with society 0002 users. How I can do this ??? thanks a lot. IsmaelH [More]
hi..guys could u plz tel me difference between index rebuild and index rebuild onlineThere is no difference in both the commands. Both will rebuild the index structure from the scratch.But in the first case with only Rebuild, as long as the index, it [More]
Dear all, Presently we are into ECC 6.00 I got following "Runtime Error RAISE_EXCEPTION" while Saving a document using T.code F-90. Short text     Exception condition "WRONG_PARAMETERS" raised Point will be rewarded, if the problem get [More]
Hi, I've just got an iPhone 5s and I don't seem to be able to copy music across to it - well I can, but only an arbitrary selection, and strangely appears to be the same songs it allows rather than entirely random. I can physically drag and drop the [More]
Any one can give the clear idea about Interface determination and Receiver Determination????????HI Gabriel <b>Interface Determination</b> An InterfaceDetermination specifies which interface is to be used for the inbound process of a message. I [More]
Lets try this again... I have a ten year old Toshiba TV (Model-SR32) that I would like to play Netflix through.  I got an Apple Component cable which has the 5 (red,red,white,yellow,green and Blue) connectors which I hooked to the colorstream outlets [More]
While coding in LV for product test rig applications there is this need to save configuration data to disk and retrieve it while running the test. A typical scenario to test product "AA" will be : 1. There are 10 different variations of the basi [More]
Good day, In t-code VF11, I want to block billing cancellation of the billing doc. whose billing date is out of FI posting period Is there any proper user-exit for it? Thanks for your quick response in advance.You can use USEREXIT_NUMBER_RANGE in MV6 [More]
Dear : we want to user the FBL3N to change the document line items field _reason code. but when we use the "MASS CHange", the system didn't allow . when I use anather one's id to change the same document numbers , it is ok. so i want to consult [More]
Is it possible to organize pdf files into folders? I was able to create a folder, but I can not move any file into it. Thank you.Sure you can... Click on Documents. Click the Edit button. Select the file(s) you want to move (red checkboxes will appea [More]