Given a binary string s, partition it into the minimum number of beautiful substrings.
A substring is considered beautiful if:
It does not contain any leading zeros.
It is the binary representation of a power of
Return the minimum number of beautiful substrings into which s can be partitioned. If it is impossible to partition s this way, return
Constraints:
s.length
s[i] is either '0' or '1'.
Given a binary string s, partition it into the minimum number of beautiful substrings.
A substring is considered beautiful if:
It does not contain any leading zeros.
It is the binary representation of a power of
Return the minimum number of beautiful substrings into which s can be partitioned. If it is impossible to partition s this way, return
Constraints:
s.length
s[i] is either '0' or '1'.