Why do Tcler suggest to brace your `expr`essions?

The “problem” with expr is that it implements its own “mini language”, which includes, among other things, variable substitution (replacing those $a-s with their values) and command substitution (replacing those [command …] things with the results of running commands), so basically the process of evaluating expr $a + $b goes like this: The Tcl interpreter … Read more

TCL can’t find mistake [closed]

There are several problems with your script. The first of which is on the first line: set QA1 array() This doesn’t do what you think it does. What it does is create a scalar variable (not an array) that contains the seven character string “array()”. Later you try to access it as an array: set … Read more