-
1 Comment
Ajay Rawat
on 5 Jan 2018
a=regexp(x,'0+','split')
a=a{max(length(a))}
y=length(a)
With this code, every test passes except 4th one. Why is it so?
Suggested Problems
-
1989 Solvers
-
783 Solvers
-
Get the length of a given vector
12449 Solvers
-
Find out sum and carry of Binary adder
1627 Solvers
-
1497 Solvers
More from this Author96
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!