If you eat enough bananas the bananas can make you gain weight because bananas are pretty high in sugar content.
That high sugar content of bananas can turn to body fat more quickly than other nutrients in other fruits and foods do.
If you eat more than 5 to 10 bananas per day you could eventually gain weight and that's a good thing if you want to gain weight but not a good thing if you're trying to lose weight.
If you're trying to lose weight then it's still okay to eat a few bananas per day as long as you're also exercising and burning off the calories and body fat.
When I was losing weight I would eat 2 bananas per day and I still lost weight because I exercised daily by jogging for 15 to 30 minutes everyday.
I would also walk whenever possible and that's both good for your health and losing weight.