def _GetInputStatusForSubmission(status, submission):
  """Return the problem input status for a submission.

  Args:
    status: user_status.UserStatus object with the current user status.
    submission: user_submission.UserSubmission object whose problem input status
      must be retrieved.

  Returns:
    An user_status.ProblemInputStatus object with the problem input status
    corresponding to the submission.
  """
  return status.problem_inputs[submission.problem][submission.input_id]