An exercise resolved as part of the IoT course at Sapienza University