3 ms·
I think my approach is better, no matter how big a file you want to store I only have to store the same amount of data... all I do is hash it first. Still work
by arethuza 17y ago
I think my approach is better, no matter how big a file you want to store I only have to store the same amount of data... all I do is hash it first.
Still working on the restore side of things, but that can't be too difficult, can it?
- jacquesm 17y agoIt's easy actually, the following code snippet will restore any file as long as you still have the hash: bignum i; for (i=0;i<MAXBIGNUM;i++) { if (hash(i) == filehash) { break; } } fprintf("%Bd",i);
- arethuza 17y agoThanks for the JavaScript!
- jacquesm 17y agoI really hope you're not serious, but on the off-chance that you are, bignum is not exactly a javascript data type and fprintf isn't a standard javascript function either. It was more of a pseudo code joke. If you weren't serious, congratulations ;)