1. Micro:bit MicroPython Basics Quiz
1.1. Question 1
Which of the following is the correct statement to import the Micro:bit library according to the provided documentation?
1.2. Question 2
According to the PEP 8 guide mentioned in the text, how many blank lines should follow a basic library import to separate it from the rest of the code?
1.3. Question 3
What happens when you use the statement ‘while True:’ in Python?
1.4. Question 4
Which of the following demonstrates a valid beginning line of an infinite loop in Python?
1.5. Question 5
When importing a module using ‘from microbit import *’, how does it affect the syntax prefix for functions like display.scroll()?
1.6. Question 6
If you want to pause your program execution for exactly 2 seconds, which code statement should you use?
1.7. Question 7
What parameter unit is accepted by the sleep() function in MicroPython?
1.8. Question 8
How are lines grouped inside a while-loop structure to show they belong inside the loop block?
1.9. Question 9
If you need a secondary pause to last for a quarter of a second, what value should be passed to the sleep statement?
1.10. Question 10
According to standard code layout principles, when are 2 blank lines used after importing modules instead of 1?