Clear variables in a list
- To: mathgroup at smc.vnet.net
- Subject: [mg112058] Clear variables in a list
- From: Chris Degnen <degnen at cwgsy.net>
- Date: Sat, 28 Aug 2010 07:01:45 -0400 (EDT)
Any suggestions how to clear variables in a list, eg: a = 1; b = 2; c = 3; vars = {a, b, c}; None of these work: Map[Clear, vars] Map[Clear[Unevaluated[#]] &, vars] Apply[Clear, vars, {1}] Only this works: Clear[a, b, c]