Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much

Re: Comparing large files

by LanX (Chancellor)
on Feb 11, 2014 at 19:30 UTC ( #1074484=note: print w/replies, xml ) Need Help??

in reply to Comparing large files

If 10 "Mg" is just the size this should result in 1e6 words.

IIRC does one hash entry result approx. 100 bytes overhead, so putting all errors in a hash should be feasible even on my pity NetBook.

Parse the pronunciation-file line by line and build a lookup hash.

Then parse the other file per line and look for missing entries.

If you really have RAM problems try splitting the hash into several disjunct ones (like for every 10% of the file) and parse the second file once for each hash.

Shouldn't take longer then seconds (at most minutes)

HTH! :)

Cheers Rolf

( addicted to the Perl Programming Language)

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1074484]
[sierpinski]: Corion I haven't -- but it sounds like you could corner the market on such a tool if you desired.
Discipulus if thezip is still around can be interested into How to hide/inhibit the console window when launching a Perl script on Windows?

How do I use this? | Other CB clients
Other Users?
Others examining the Monastery: (13)
As of 2017-03-27 19:11 GMT
Find Nodes?
    Voting Booth?
    Should Pluto Get Its Planethood Back?

    Results (321 votes). Check out past polls.