Create sample input using windows batch file

Script that did my job

@echo off

setlocal EnableDelayedExpansion

for /L %%F IN (1,1,100) DO (
set /a year = !RANDOM! %% 12+2000
echo !year! !RANDOM!
)

endlocal

Generates random numbers. First column contains year between 2000 to 2012 second column contains a random number. You would have to tweak for your requirement.

Did your day just got saved? ! 🙂

Oh and by the way you can direct your output to a text file as

<filename>.cmd > mysampleinput.txt

:p

 

References

You may also like...

Leave a Reply

Your email address will not be published. Required fields are marked *