New answers tagged

3

Since you referenced How do I evaluate only one step of an expression? I might use: (* step loaded from referenced Q&A *) mySet[str_String, val_] := step @ Symbol[str] /. _[s_Symbol] :> (s = val) Now: x = 5; mySet["x", 7]; x 7 (This also makes use of Injecting a sequence of expressions into a held expression.) For clarity the above is ...



Top 50 recent answers are included