text: Goals In general, batters try to get hits. However, their primary objective is to avoid making an out, and helping their team to score runs. There are several ways they can help their team score runs. They may draw a walk if they receive and do not swing the bat at four pitches located outside the strike zone.  In cases when there is a runner on third and fewer than two outs, they can attempt to hit a sacrifice fly to drive the runner in by allowing the runner on third to tag up and score.  When there are fewer than two outs and runners on base, they can try to sacrifice bunt to advance the runner(s) or, with a runner on first or with runners on first and third, they can try a hit and run play, also designed to advance the runner(s).  They might even be hit by a pitch, reach on an error or—if first is empty or there are two outs—on a dropped third strike.
  The defense attempts to get the batter out. The pitcher's main role in this is to throw the ball in such a way that the batter either strikes out or cannot hit it cleanly so that the defense can get him or her out.