KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
I have two lists of equal length, with no spaces in the individual items: list1="a b c" list2="1 2 3" I want to iterate over these two lists in parallel, pairing a with 1, b with 2, etc.: a 1 b 2 c 3 I'm attempting to support modern portable Bourne shell, so Bash/ksh arrays aren't available. Shelling out to awk would be acceptable in a pinch, but I'd rather keep this in pure sh if possible. Thank you for any pointers you can provide!
Tags (comma-separated)
Save Edits
Cancel