Help Required in shell scripting

Hi,
I am new to Unix shell scripting.I have a requirement where I have to search for a particular file in a Unix directory based on some criterian of the content of the file.Actually there would be two files with same name and then I have zip them together and stoe in the same directory.
As the file names are dynamic, So it would be helpful If i get an shell script meeting all the requirements.

Please define the problem clearly.what should be the criteria to look in the file?what is the filename like?