You can't tell me that living with a friend would be a crime. I'm not talking about a lease, I'm talking about charity.
Then how does one go about finding such a friend willing to offer such charity? Perhaps it appears easy to you, but a lot of people remain homeless because they lack certain social skills. This could result from autism spectrum disorder, schizophrenia, past abuse, or any of several other conditions.
So, kind of like "no one stays in shelters; there's too many people there."
Yeah, obligatory Yogi Berra, I know, but let me rephrase: No one can rely long-term on staying in shelters because it is too likely that on a given night, there are too many people there.
Setting foot in a different country is a crime? You'll need to explain that one a little more.
The Wikipedia article titled "Illegal immigration" should serve as a convenient starting point.
I was assuming, though, that one could find another city with different laws. Where I live, there are sit/lie laws. There are a half-dozen cities in the region that don't have them, and they become known as places with lots of homeless people around.
And I was assuming that the lack of sit/lie laws in those half-dozen nearby cities would not last forever because those half-dozen nearby cities would want to try to shake that perception.
In the U.S. at least, there aren't national laws outlawing being homeless; those are usually left to cities, and those laws vary place-to-place.
Then how should somebody who is already homeless go about researching which nearby cities both A. lack a sit/lie law and B. are highly unlikely to adopt one in the next twelve months?