ServiceTitan Interview Question

Check the brackets