_sourcemod_builtins.py 文件源码

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

项目:leetcode 作者: thomasyimgit 项目源码 文件源码
def regenerate(filename, natives):
        with open(filename) as fp:
            content = fp.read()

        header = content[:content.find('FUNCTIONS = (')]
        footer = content[content.find("if __name__ == '__main__':")-1:]


        with open(filename, 'w') as fp:
            fp.write(header)
            fp.write(format_lines('FUNCTIONS', natives))
            fp.write(footer)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号