Mega Goomba (boss)
From the Super Mario Wiki
Ads keep the MarioWiki independent and free :)
Before the battle, a seemingly regular Goomba transforms into Mega Goomba. When it grows, it makes a sound similar to touching a Mega Mushroom, only somewhat more menacing. Mario must defeat this boss to acquire the key that provides access to World 5.
To defeat Mega Goomba, Mario can activate a switch, causing two platforms to appear. When Mario stands on the platform, it will elevate in the air. From there, Mario can either Wall Jump, Jump, or Ground Pound directly on top of Mega Goomba. For the attack to be successful, Mario must Ground Pound the Goomba (unless he is Mega Mario or Shell Mario). Mario can also go off to the side, simply wall jump, then ground pound on Mega Goomba. It is possible to defeat Mega Goomba without using the ? Switch. To do this Mario or Luigi must perform Wall Jumps. Fire Mario can also defeat Mega Goomba if Fire Mario stays on the far left area and shoots enough fireballs to defeat him; when Mega Goomba approaches Mario on the far left side, he does not hurt Mario due to his mushroom-sized hitbox.
Once Mario Ground Pounds Mega Goomba three times (or nine times if Mario is in Mini form), the Goomba will be defeated, and Mario can get the key to World 5.
Names in other languages