in most jurisdictions you are legally an adult at 18 years of age
with all the benefits and responsibilities that go with it
like providing for yourself
translation parents have to provide for kids and put up with their Crap until they are adults
beyond that the little buggers are on their own and will live or die accordingly
That is not the way laws are written. Instead, there are laws that say that a parent has an obligation to provide housing to a child. A child is then defined as someone under 18. So, the obligation to provide housing (and food and medical care and such) extends only until the child is 18.