<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_version(path, default="master"):
 """ Return the version from a VERSION file """

    version = default
    if os.path.exists(path):
        version_contents = file_to_string(path)
        if version_contents:
            version = version_contents.strip()

    return version