human
generate random binary number with certain number of bits.
assistant
Here is a Python function to generate random binary numbers with certain number of bits

import random

def random_binary_number(bits):
    """
    Generate random binary number with certain number of bits.
    """
    return ''.join([random.choice(['0', '1']) for _ in range(bits)])

# Enter the number of bits
bits = 10

# Calling the function
print((random_binary_number(bits)))

#Example Output
# 0111100111

#Remember to inspect code for bugs.