Is this tennis?
If it is, it depends whether or not it went out after it bounced in Team B's box. If it did, it's Team A's point. If it didn't, it's Team B's point. And if they're still in the same game, then Team A serves.
Basketball?
No points for either team; it's team B's ball.
Volleyball?
Team B's point; Team B serves.
I'm sorry if I didn't get the sport you were talking about. The question wasn't very specific...