code: def _cmp_fn(name, op, self_tuple, other_tuple):
      # Create a comparison function.  If the fields in the object are
      # named 'x' and 'y', then self_tuple is the string
      # '(self.x,self.y)' and other_tuple is the string
      # '(other.x,other.y)'.
  
      return _create_fn(
          name,
          ("self", "other"),
          [
              "if other.__class__ is self.__class__:",
              f" return {self_tuple}{op}{other_tuple}",
              "return NotImplemented",
          ],
      )
  
imports: import re
  import sys
  import copy
  import types
  import inspect
  import keyword
label_desc: Use image node_id 10 for calling a global function with example usage: _cmp_fn(name, op, _tuple, other_tuple) and returns: _create_fn