The drugs were my boyfriends. However, is not live me anymore.
I don't believe there is a hard and fast rule regarding distance between contraband and defendants. If you have been arrested, you need to retain experienced criminal defense counsel.
Attorney Thygerson is exactly right. There is no rule; the fact that the drugs were recovered in your residence is a problem for you. There may well be any number of defenses open to you, but you will not know about them until you start talking to local attorneys with experience in drug defense. Good luck.
In Maryland, there is a doctrine of law called "constructive possession." A person can be imputed with possession of an item if he or she demonstrates dominion or control over it. Whether they have dominion or control depends on several factors, including distance from the accused to the item, size of the room, visibility of the item, evidence of common use, etc. More than one person can "possess" the same CDS under this doctrine.
If you have been charged with a crime, you should engage an attorney immediately. If you cannot afford one, apply for the services of the public defender.