Random variable not changing in “for” loop in windows batch file

后端 未结 2 1254
无人及你
无人及你 2020-12-06 11:05

I\'m trying to print out a Random number multiple times but in the for loop I use, it doesn\'t reset the variable. Here\'s my code.

@echo off


for %%i in (*         


        
2条回答
  •  难免孤独
    2020-12-06 11:20

    on my system I have to write

    set checker=Random
    

    instead of

    set checker=!Random!
    

提交回复
热议问题