@DEC[string] : Returns :


-1 if string is empty

otherwise the same value as @EVAL[string - 1]


If string is the name of an environment variable, its value is used whether or not it is preceded by a percent sign % without modifying the value of the variable. To actually decrement the value of the variable var use:


set var=%@dec[%var]




set start=5

set result=%@dec[start]

echo %result