Moveo Group Interview Question

online task to do machine loop