<pre>for %h in (x y) do for in (g p c d) do echo %h</pre>

I had a need to iterate a DOS Batch file through two backup drives and through four local drives for each backup drive.
I'd forgotten (!) about the FOR command.
Some reading here http://commandwindows.com/batchfiles-iterating.htm