What historical event directly led to the end of available frontier lands for settlement?

A) Homestead Act of 1862

B) 1849 Gold Rush

C) Oklahoma Land Rush

D) Railroad Act of 1862