What you learn today
- Quiz on math instructions, rand and smoothing
This week was about math and about programming sparingly:
- Saving registers:
defineandaliascost nothing, onetmpmay be many things, states move into the stack withputandget. - hcf: error 16, a spark, a small explosion – and the devices keep their last value. A lock state with acknowledgement is better.
- rand: 0 to below 1, scaled with
mul,addandfloor. - sqrt, pow, exp, log:
logis the natural logarithm, log10 only exists as log(x) / log(10). - Smoothing: moving average or g = g + a · (x − g), with a start value and NaN guard.
- Project: light scenes with an edge, stepwise dimming and random flicker.
You pass from 60 %. The explanations after handing in sum up every point once more.
Weekly quiz
12 questions. You pass from 60 % – the server does the grading.
Complete the day
- Passed the quiz with at least 60 %
Without an account progress is saved in this browser only.
Report a mistake in this lesson
Please sign in to report. Sign in