code: def set_variable(self, name, value):
          
          if value is None:
              # Unset the variable.
              if name in self._var:
                  del self._var[name]
          self._var[name] = value
docs: Set a bot variable.
  
          Equivalent to ``! var`` in RiveScript code.
  
          :param str name: The name of the variable to set.
          :param str value: The value of the variable.
              Set this to ``None`` to delete the variable.