Getvalue() help

Please remember to post a minimum working example that demonstrates what you tried, and what the error was:

In this case, x isn’t a single variable, so you probably want something like

for i in 2:4
    println("x[$(i)] = ", 2 * getvalue(x[i]) + 2)
end 
1 Like