Robert Bosch Interview Question

Coding question count the no of 01 and 10