LI:To learn how to code the Microbit in Python
This first one shows the Python codingfor a flashing heart. It flashes between a small heart icon and a large heart icon.The main thing to notice between the Python coding and the bkocks is that the forever loop is at the top and bottom of the content in both.
For this example for coding the buttons, the main thing to notice is the "def" whcih is defining hat the on_button_presses will amke the microbit do.Again this ahs a top and bottom so the contest has to go inside it.
Something I found interesting about using coding in Python is being able to write the steps instead of using blocks.
No comments:
Post a Comment