code: def variable_name_from_full_name(full_name):
      
      projects, _, configs, _, variables, result = full_name.split("/", 5)
      if projects != "projects" or configs != "configs" or variables != "variables":
          raise ValueError(
              "Unexpected format of resource",
              full_name,
              'Expected "projects/{proj}/configs/{cfg}/variables/..."',
          )
      return result
docs: Extract the variable name from a full resource name.
  
        >>> variable_name_from_full_name(
                'projects/my-proj/configs/my-config/variables/var-name')
        "var-name"
        >>> variable_name_from_full_name(
                'projects/my-proj/configs/my-config/variables/another/var/name')
        "another/var/name"
  
      :type full_name: str
      :param full_name:
          The full resource name of a variable. The full resource name looks like
          ``projects/prj-name/configs/cfg-name/variables/var-name`` and is
          returned as the ``name`` field of a variable resource.  See
          https://cloud.google.com/deployment-manager/runtime-configurator/reference/rest/v1beta1/projects.configs.variables
  
      :rtype: str
      :returns: The variable's short name, given its full resource name.
      :raises: :class:`ValueError` if ``full_name`` is not the expected format