BETA
School Problem's Submission isn't counted in score!

Total Submissions: 194 Accuracy:

36.08%

longest substring containing '1' (Function Problem)
     

Given a function that takes a binary string. The task is to return the longest size of contiguous substring containing only ‘1’.

Input:
The first line of input contains an integer T denoting the no of test cases.Then T test cases follow. Each test case contains a string S.

Output:
For each test case return the maximum length of required sub string.

Constraints: 
1<=T<=100
1<=|string length|<=104

Example:
Input:

2
110
11101110

Output:
2
3

** For More Input/Output Examples Use 'Expected Output' option **

Contributor: Arun Tyagi


					   
It is recommended to 'Compile & Test' your code before clicking 'Submit'!

Compilation/Execution Result:

Need help with your code? Please use ide.geeksforgeeks.org, generate link and share the link here.