# Evaluate within Hold

When I do...

p=3;
HoldForm[Evaluate[p]-2]


I get:

Evaluate[p]-2


BUT I'd like to get:

3-2


How can I get this result? I want to display the subtraction, unevaluated -- but I want an expression within the subtraction to get evaluated.

• Why not With[]? With[{p = 3}, HoldForm[p - 2]] – J. M.'s technical difficulties Mar 15 '16 at 3:25
• @J.M. Yes that is better. Why not add a separate answer? – Sean Mar 15 '16 at 3:31
• Because that bit is also in the thread you linked to, and the threads that thread is linked to. – J. M.'s technical difficulties Mar 15 '16 at 3:33

HoldForm[p - 2] /. HoldPattern[p] :> RuleCondition[p]

• Sean, perhaps you could add the With method outlined by J.M. in your answer, since you found it useful as well. (+1 for self-answering!) – MarcoB Mar 15 '16 at 3:43