ANONYMOUS wrote:
> Hi, at first time, I stored the files information by reading different directories. For example there are 2 directories provided by command line, and the I allocate two chunck of memories to store information of files included in the directory.
> However, when doing the step "identify exit only or files with same filenames", I found it is difficult to search by filename (especially when have 2+ directories)
> So, I was wondering can I store files in a hash table( inspired by lecture 19), which is an array of list, each list have the files with same filenames and same relative location.
> And because I am not yet doing recursive (-r) option, so I am not sure, this structure is easy for recursion, becuase in recursion situation (not figure out yet) how to identify the files in same relative location. Thank you.
You may choose any data-structures, or a combination of data-structures, that you wish.
I really don't know what "two chunck of memories" means, but there's no need to explain.