<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def get_tuple_version(name, default=DEFAULT_TUPLE_NOT_FOUND, allow_ambiguous=True):
 """ Get tuple version from installed package information for easy handling. It will return :attr:`default` value when the named package is not installed. Parameters name : string An application name used to install via setuptools. default : tuple A default returning value used when the named application is not installed yet allow_ambiguous : boolean ``True`` for allowing ambiguous version information. Returns -------- string A version tuple Examples -------- True True True True (0, 0, 0) """

    def _prefer_int(x):
        try:
            return int(x)
        except ValueError:
            return x
    version = get_string_version(name, default=default,
                                 allow_ambiguous=allow_ambiguous)
    # convert string version to tuple version
    # prefer integer for easy handling
    if isinstance(version, tuple):
        # not found
        return version
    return tuple(map(_prefer_int, version.split('.')))