If (Box A Taken = True)
{place ($0) in Box B}
else
{place ($1,000,000,000) in Box B}
Machine doesnt care if you also take Box B, it only cares if Box A is one of the boxes taken. If you take no boxes, Box B would still have a billion dollars, although thats kinda dumb choice from a gameshow host's perspective.