Linux: create list of text with multiple operators

view full story

http://unix.stackexchange.com – I want to make a list like this: 7785237_770x770_de3b540dc13ed50023d17854513b40aa07e50a6a 732308_770x770_ec5c344c0114011a5306b31142ff9b001813f6d6 7430796_800x800_ec0f2e614e2dc460fca7e626d83073c827dc9130 7431018_800x800_7caa40b85c21485c64f2ad509a0d9cc1ed3ba526 So to explain: First block before the first "_" is just a number between 0 and 9500000 - second block varies between two variables: "770x770" and "800x800" Last block is a 40 character long HEX block. So what I want to do, is to generate all possible combinations of these, and combine it into one line. How do I do this? Don't know if (HowTos)