For "A":
The pure result of the play is an apparent touchdown for B.
The accepted penalty for the holding foul by B would be a Basic Spot/3 and 1 enforcement. The foul occurs during a running play that ends behind the neutral zone. The previous spot is the Basic Spot, and fouls by the opponents of the team in possession (at the time of the foul) are penalized from the Basic Spot. 10 yards, repeat the down. A, 1/10, A-25 (clock starts on the snap, because of the apparent score by B).
For "B":
The pure result of the play is a safety - 2 points for B.
If accepted, the penalty for the holding foul by A would also result in a safety - 2 points for Team B (by rule).
A, Free Kick, A-20.
So, what do you do as the Referee? Safety as result of the play and decline the penalty? Or safety by penalty? Doesn't really matter to us - but those keeping stats may want to record the official yardage (lost by A) by the result of the play, that would not be recorded if the penalty is accepted. Seriously. Had a team complain when we rang up the safety by penalty on a similar situation - they wanted to be able to claim the lost yardage for their defensive stats. Really.
Robert