Olympics and WC do cost a lot of money, but Brazil's economy is so much bigger than Greece's (to name one) (10 times bigger precisely). Both of them should come bundled with lots of infrastructure investiment... which sadly is not what happened. But it woudn't be even without these games being held in Brazil.
The way our politicians play with money is ridiculous. Maracana Stadium has been 'under construction' more time than it's been open for football matches in this century. around the year 2000, then again for 2007 Panamarican Games, then again for WC, and now again for the Olympics. They spent 1 billion reais (~300-400 million dollars depending on when you check the conversion rate) for the WC, and then 'sold' it for 150 million reais for a private company to take care of it. Wow, such a great deal. They built a complete watersports complex for Panamerican games just to destroy it a few years after, and now are building another one again for the Olympics.
Many airports that should have been improved for WC were not, many transportation projects didn't come to life (trams, bus lanes, metro lines)...
I wish all the investment was properly done, could have meant lots of improvement for the people.