If your friend did the breaking up, its more socially acceptable to date your friends ex. Under all circumstances, it would be a nice idea to just ask your friend politely if he or she is okay with it. He or she may still have feelings for the ex, even if it happened a long time ago.
Is it weird if I like my cousin?
Khurki would say its perfectly normal. Remember having a crush on your cousin doesnt make you a bad person or freak. It happens at a stage when teenagers start developing feelings for the opposite sex and if you are happy being close to your cousin, it is okay!
How do I tell my best friend I like her ex?
Just be honest, tell her you have feelings for her ex, and ask her if she would mind if you went out with him. If they did have a bad breakup and/or if she tells you she wouldnt be comfortable with the two of you dating, just try to move past these feelings. Its not worth losing your friend.