def get_problem_instance(pid, tid):
"""
Returns the problem instance dictionary that can be displayed to the user.
Args:
pid: the problem id
tid: the team id
Returns:
The problem instance
"""
problem = deepcopy(get_problem(pid=pid, tid=tid))
instance = get_instance_data(pid, tid)
problem['solves'] = api.stats.get_problem_solves(pid=pid)
problem.pop("instances")
problem.update(instance)
return problem
评论列表
文章目录