For example, if Justin Upton gets 155 hits in a season and has 554 at bats, his batting average would be 155/554, or .280. The batting average is usually represented not as a percentage (i.e. 28.0%), but instead as a decimal number with three places after the decimal. A batting average of 1.000 means that the player gets a hit every time he comes to bat, and an average of .000 means the player has no hits.
It should also be noted that not every time a batter comes to the plate counts as an at bat. Plate appearances that do not count as at bats include walks, hit-by-pitches, sacrifices, etc.