Created
August 31, 2017 05:07
-
-
Save jimmo/8f0fd34de9fcd4586dc5006b9fe21c79 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from microbit import * | |
| time_last_press = 0 | |
| while True: | |
| if button_a.was_pressed(): | |
| time_now = running_time() | |
| display.show(str(time_now - time_last_press)) | |
| time_last_press = time_now |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment