ADVI Groups interview question

Solve the bug in this code.The code was focused on collecting data from sensors and it was in python.