generate_resources.py 文件源码

python
阅读 19 收藏 0 点赞 0 评论 0

项目:EasyEuler 作者: Encrylize 项目源码 文件源码
def cli(problem, path):
    """
    Generate the resource files for problems.

    These resources are either images - serving as helpful illustrations -
    or text files containing specific data - referenced in the problem.

    If the PROBLEM argument isn't specified, all resources will be
    generated.

    """

    if problem is None:
        resources = os.listdir('%s/resources' % paths.DATA)
    else:
        if 'resources' not in problem:
            sys.exit('Problem %s has no resource files' % problem['id'])
        resources = problem['resources']

    generate_resources(resources, path)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号