You made me laugh out loud. LOL.
Yes, beef cattle roam and graze on large tracts of land in the west. There are still real cowboys on horses, herding dogs, and also they now use ATV's and small aircraft, and GPS tracking, to find the cattle when the owners want to round them up.
I knew a guy who owned a $50,000 Black Angus breeding bull they couldn't find. They took their small plane out (they also made money leasing their plane to other ranchers for the same purpose) and found him dead in a ravine. I said if I owned a $50,000 bull, he'd have his own bedroom inside my house!
Dairy cows must be tended to daily, milked. They are likely to have barns and a combination of green grass pasture grazing and daily feeding of corn, hay, etc. So you are correct. They tend to live and produce for several years.
Beef cattle are grown for slaughter and breeding. They have short lives.