FAQ
Hello all

I must compare the contained of several directories in several pcs. Each
directory must contain about 17000 files.

Do you know any special method to compare the lists of listdir quickly?

Thanks

Enrique
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.python.org/pipermail/python-list/attachments/20030320/134e6b36/attachment.htm

Search Discussions

  • Martin Franklin at Mar 20, 2003 at 9:45 am

    Enrique Palomo wrote:
    Hello all

    I must compare the contained of several directories in several pcs. Each
    directory must contain about 17000 files.

    Do you know any special method to compare the lists of listdir quickly?

    Enrique,


    Lists can be tested for equality with == but I suspect this is too
    simplistic.
    So my question is what exactly do you want to compare?


    Martin
  • Peter Hansen at Mar 20, 2003 at 11:45 am

    Martin Franklin wrote:
    Enrique Palomo wrote:
    Hello all

    I must compare the contained of several directories in several pcs. Each
    directory must contain about 17000 files.

    Do you know any special method to compare the lists of listdir quickly?
    Enrique,

    Lists can be tested for equality with == but I suspect this is too
    simplistic.
    So my question is what exactly do you want to compare?
    Or perhaps, "what do you expect to happen as a result of the
    comparison"? I suspect he wants some kind of "diff" happening
    here...
  • Mark McEahern at Mar 20, 2003 at 12:47 pm
    [Enrique Palomo]
    I must compare the contained of several directories in several pcs. Each
    directory must contain about 17000 files.
    Do you know any special method to compare the lists of listdir quickly?
    As others have pointed out, you haven't been terribly clear about what you
    think "compare" or "quickly" means--so I'll just ignore that and suggest you
    check out the filecmp module in the standard library. <wink>

    Cheers,

    // m

    -

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
grouppython-list @
categoriespython
postedMar 20, '03 at 9:32a
activeMar 20, '03 at 12:47p
posts4
users4
websitepython.org

People

Translate

site design / logo © 2022 Grokbase