Maximize count of strings of length 3 that can be formed from N 1 s and M 0 s | Function that counts the number of strings of length 3 that can be made with given m 0 s and n 1 s ; Print the count of strings ; Driver Code ; Given count of 1 s and 0 s ; Function call
def number_of_strings ( N , M ) : NEW_LINE INDENT print ( min ( N , min ( M , ( N + M ) // 3 ) ) ) NEW_LINE DEDENT if __name__ == ' _ _ main _ _ ' : NEW_LINE INDENT N = 4 NEW_LINE M = 19 NEW_LINE number_of_strings ( N , M ) NEW_LINE DEDENT