the LEGO Group Interview Question

Q: Solve this given problem