I’m obsessed with someone who isn’t good for me how to get over them?

I have a problem I’m attached to someone who I can’t be with nor he is good for me.
I’m obsessed with someone who isn’t good for me how to get over them?
Post Opinion