Array comparision in bash shell

view story

http://www.unix.com – I'm not sure if i can put the problem in understandable form.Let me try: I have a array which is like and always fixed: Array1=(new inprogress pending Restored Resolved ) Other 2 array array2 which may varry but always subset of above array: Like it can be : Array2=(New inprogress Resolved) Array 3 always corresponds to array2. Which says time spent in each state if array2.Like Array3=(2min 3 min 4min) Now, i have to display the time spent for each state of array2 in the order they are in array1 and if any element of array1 doesnt exist in array2 implies its 0 min. So in above exam (HowTos)