To calculate the density of an object, you can use the formula:
\[ \text{Density} = \frac{\text{Mass}}{\text{Volume}} \]
In this case, the mass of the ball is 100 grams and the volume is 2 cubic centimeters (cm³).
\[ \text{Density} = \frac{100 \text{ g}}{2 \text{ cm}^3} = 50 \text{ g/cm}^3 \]
Therefore, the density of the ball is 50 g/cm³.