For example, instead of for I want to write аа . I tried it
proc aa {abcd} { for {$a} {$b} {$c} {$d} } aa {set k 0} {$k<5} {incr k} {puts $k} but failed.
For example, instead of for I want to write аа . I tried it
proc aa {abcd} { for {$a} {$b} {$c} {$d} } aa {set k 0} {$k<5} {incr k} {puts $k} but failed.
Try passing the arguments to the for command directly, with no additional braces around the arguments:
$ tclsh % proc aa {abcd} { for $a $b $c $d } % aa {set k 0} {$k<5} {incr k} {puts $k} 0 1 2 3 4 % % # проверка % for {set k 0} {$k<5} {incr k} {puts $k} 0 1 2 3 4 % Source: https://ru.stackoverflow.com/questions/455572/
All Articles
scriptlabel, specify the programming language. - Visman