Block Editor
In this next example using the block editor we will use the accelerometer that is on the Micro:bit board to detect when the micro:bit is being shaken, if it is.
The pins on your Micro:bit that are labelled 0, 1 and 2 can be used as touch inputs. To do this you need to touch the ground pin with one.