Arduino Whack a Mole

For this challenge we will create a a game of Whack-A-Mole using an Arduino device/board, three LEDs, three push buttons and a piezo buzzer.

You do not need to have access to an Arduino board. Instead you can use the online Arduino simulator from Tinkercad to recreate the electronic circuit and add the code provided below.

Open Tinkercad in new window

Electronic Circuit


First you will need to recreate the following electronic circuit:
arduino-Whack a Mole

C/C++ Code


Then you will need to use the following code (When using tinkerpad, choose the text option rather than blocks)

Did you like this challenge?

Click on a star to rate it!

Average rating 5 / 5. Vote count: 1

No votes so far! Be the first to rate this post.

As you found this challenge interesting...

Follow us on social media!

Tagged with: