In this tutorial we will control the lighting of two LEDs (red and green) via the two buttons A and B of the micro: bit card:
1- When you press button A, the green LED turns on and the red LED turns off.
2- When you press button B, the red LED turns on and the green LED turns off.
To perform the assembly, you can connect the green LED to pin P0 and the red LED to pin P1 of the micro: bit card.
There are many mounting methods and here are some examples:
Here is the makecode program which allows you to light 2 LEDs: