simple question?!

i´m trying to figure out how does ip address with a variable works.
i´m getting errors with the following sentence

:for i from=1 to=21 do {/ip route add dst-address=(i$.“.”.0.“.0.”.0"/8") gateway=172.16.2.1} doesnt work

here an example that works.. i dont know how that extra “.” works..

:for i from=0 to=255 do={/ip address add address=(“7.” . $i . “.” . 1 . “.1/30”) interface=lan} works..

Thanks!

Best way to write it in v3.x

:for i from=1 to=21 do={/ip route add dst-address="$i.0.0.0/8" gateway=172.16.2.1}

thanks!