SmartThings Interview Question

how would you design a vending machine system