Amazon Interview Question

Code for finding number of consecutive 1s in a circular array.