This program counts the number of passing cars on the road. This program has an O(N) time complexity.