If pattern "01" appears then increase the occurrence of pattern
if string [ currlen - 1 ] == 0 and nextbit == 1 : NEW_LINE INDENT occur += 1 NEW_LINE DEDENT generateBinStr ( string , length , currlen + 1 , occur , 0 ) NEW_LINE generateBinStr ( string , length , currlen + 1 , occur , 1 ) NEW_LINE