Question: You are given an array arr which consists of only zeros and ones, divide the array into three non - empty parts such that all

You are given an array arr which consists of only zeros and ones, divide the array into three non-empty parts
such that all of these parts represent the same binary value.
If it is possible, return any i,j with arr[i+1],arr[i+2],dots,arr[j-1]
 You are given an array arr which consists of only zeros

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!