Zero String Codechef Starters 76 (Rated till 5-Stars) problem solution
This post is all about the solution of the Zero String Codechef Starters 76 (Rated till 5-Stars) problem solution.
Problem Statement:
You are given a NN-length binary string SS. You are permitted to perform the following operations on string SS:
Concatenate the remaining parts of the string after removing any one character from SS. For example, removing the third character from S = 1101S=1101, we get S = 111S=111.
Flip all of SS's characters. For example, if we flip all of the characters in S = 1101S=1101, we get S = 0010S=0010.
Given that either type of operation can be used an unlimited number of times, calculate the smallest number of operations required to make all characters in the string SS equal to 00.
Format of Input :
The number of cases will be indicated by a single integer TT in the first line of input.
Each test case's first and only line includes 2 space-separated integers NN and MM — the number of apples and oranges, respectively.
Format of the Output :
For every test case, output YES if the group is perfect and NO or else on a new line.
Each character can be printed in either uppercase or lowercase. The strings YES, yes, Yes, and yES, for example, are all considered identical.


0 Comments