Texas has a diverse landscape ranging from mountains and forests to coastal plains. It has a mostly hot, dry climate but temperature varies by region. Six flags have flown over Texas since it was first settled by Americans in the 1820s when it was part of Mexico. Texas gained independence from Mexico and became a republic in 1836 after battles at the Alamo and San Jacinto, and it later joined the United States as a state in 1845. The state is known for oil and cattle production as well as native plants that thrive in its climate with little water.