<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def download(name, verbose=False):
 """ Download a dictionnary from the remote server into the local cache. Return the number of new words or -1 on error. """

    init_storage()

    if verbose:
        print("Downloading '%s'..." % name)
    r = get_remote_file('%s/%s.txt' % (DICTS_URL, name))

    if r.status_code != 200:
        return -1

    wcount = 0

    with open(os.path.join(DICTS_PATH, '%s.txt' % name), 'w') as f:
        for word in r.iter_lines():
            wcount += 1
            f.write('%s\n' % sanitize_word(word))

    if verbose:
        print("%d words added." % wcount)
    return wcount