Why is ego a bad thing in BJJ? If you are so full of yourself and too damn proud to tap to anybody you will get hurt, it is inevitable. No matter how long, how hard, how experienced, how strong, etc... you are or you think you are, if a 1st day white belt or anybody that you believe you are better than you puts you in a submission that you cannot escape you need to tap. It happens to everybody, everybody gets submitted. At the end of the day, you need to put your ego aside and admit to getting caught, admit to not being able to escape. You can grow so much from your mistakes. Getting caught in a submission means you have a hole in your game or you made a mistake. You need to learn why you were put into that position, why you left a hole in your defense and learn how to not make that same mistake again. Having an ego and fighting to the point where something pops is stupid. You could possibly still learn from what you did to get caught in a submission, but you will learn that your first mistake was not tapping. And you will have learned it the hard way. Getting hurt and having to take time off due to not tapping is stupid and unnecessary.
Why is ego a good thing? A little ego is needed to progress your training, I think the correct word would be confidence, but there is a very fine line between the two. Again having too much may make you feel safe in positions you should not feel safe at all and too little will keep your mindset on the defensive. I wouldn't go so far as to think like Rickson Gracie, he once said "I'm afraid of everything," I think that is too extreme, but you do need to know where and when to feel confident. If you have no ego, you will likely be stuck at the same level you are at. Not to say you won't learn anything, but it will make it tougher on you as an individual to push yourself. For example, if you are going to roll with somebody that always beats you and submits you in 1 minute and you believe that it will always be that way, then it probably will. You need to learn how to tell yourself that you are confident enough to survive for 2 minutes! Tell yourself that he/she can't possibly submit you in 1 minute today. If it happens, it happens. However, if you fought hard to avoid getting submitted for 2 minutes then you have broken a barrier of yours and made a step towards your progression in the art. Keep in mind too that BJJ is a two way street, when you push yourself you also push your training partner, your teammate. So when you get better, you also make your training partners better, no matter who submitted who more.
It is difficult to find the right balance of ego when you train. I know I struggle with it from time to time and I've been training for over 8 1/2 years. Just keep in mind that it isn't always a bad thing, but that also too much of it can be a very bad thing.