What is the function of the scrotum in the male reproductive system?

Factory of sperm cells

The scrotum serves as the production center of sperm cells, which are responsible for fertilizing an egg cell.