SAP interview question

Valid perfect square, and street lights problem (simulation)