From the Super Mario Wiki
One Wiggler is on the top screen and many are on the bottom. The player must touch the Wiggler that matches the Wiggler on the top screen and if correct, the player gains five seconds to the time limit and a new one begins. If the player picks the wrong Wiggler, then it will get angry and turn red, and it will deduct 10 seconds from the player's time limit. The Wigglers start out sleeping for the first few levels, but begin to move afterward, increasing the difficulty. The circles on the top Wiggler is the hint to finding the bottom one.
This minigame also appears as a Puzzle minigame in New Super Mario Bros., where choosing incorrectly subtracts one from the player's score, if playing multiplayer.
 In-game instructions
Touch the Wiggler on the Touch Screen that matches the one on the top screen. Choose carefully, though; he has a terrible temper.