I think it depends greatly on the situation and the person. If it feels right go for it. As strawberry said though, if it's just as a rebound maybe take it slow for a bit so you or someone else doesn't get hurt more.
I agree with what's been said. In these situations it's really important to be honest with everyone involved, especially yourself. It's never good to get into a relationship if you're not truly ready. You can't use another person to get over your ex and expect it to work out.
I think it depends on the situation. I've done this before and it had worked out okay for me, but I had already been pulling back emotionally from the previous relationship a couple months before because I saw that it was going to end anyway.
However I've also jumped into relationships too quickly and it really messed with me emotionally and hurt both of us. You are going to be the best judge as to whether or not you are ready for a new relationship.