I haven't seen any data showing if people became addicted to drugs first and then became homeless due to that or if it was the other way around. I can totally see people becoming homeless first and then getting addicted to drugs because being homeless sucks. Again, haven't seen any data to show which way happens more often but the data showing rates of homelessness are lower in areas with lower housing costs is pretty telling.