code: def subs(d, **kwargs):
      """Full simultaneous exact substitution.
  
      Examples
      ========
  
      >>> from sympy.strategies.tools import subs
      >>> from sympy import Basic, S
      >>> mapping = {S(1): S(4), S(4): S(1), Basic(S(5)): Basic(S(6), S(7))}
      >>> expr = Basic(S(1), Basic(S(2), S(3)), Basic(S(4), Basic(S(5))))
      >>> subs(mapping)(expr)
      Basic(4, Basic(2, 3), Basic(1, Basic(6, 7)))
      """
      if d:
          return top_down(
              do_one(*map(rl.subs, *zip(*d.items()))), **kwargs
          )
      else:
          return lambda x: x
  
imports: from .None import rl
  from .core import do_one, exhaust, switch
  from .traverse import top_down
label_desc: Use image node_id 1 for calling a global function with example usage: subs(d) and returns: top_down, function