Windows – Batch file to create multiple folder and subfolders

batch-filecommand linewindows

Need help:

We want to create a batch file in DOS (run at command prompt) which will create 50 folders (e.g. folder1, folder2, folder3 etc…) and also create subfolders (filesin, filesout) in each of them.

Regards

Best Answer

for /L %%g in (1,1,50) do (
    md folder%%g
    md folder%%g\filesin
    md folder%%g\filesout
)