nicomen
05-11-02, 13:51
| I am *very* new to shell programming, so please be gentle. I am trying to write a small script using a nested foreach loop. I have 4 files which contain a list of numbers, and one file that contains the bad numbers that are contained in the above-mentioned 4 files. I would like to be able to match up (from bad number file) the bad numbers listed in the 4 files, but I'm not sure how to make the one file search the other 4...? I've looked in various sites and cannot seem to find anything that gives me a hint...so any help would be appreciated. Here's a rough of what I am trying to construct: foreach i ( file1 file2 file3 file4 ) foreach j ( ~/badnum ) ...and then I'm not sure...I'm thinking tho, that in my "foreach j" I may need to "cat badnum"? Thanks in advance nicomen |