FedEx Interview Question

Count number of boxes in image.