Geotab Interview Question

A logical thinking question followed by a javascript question