def fromiter(iterable):
    """
    Construct a binary number from a finite iterable, where the ith bit
    from the right is the truth value of the iterable's ith item.
    
    :param iterable: any iterable, usually one with boolean values.
    :type iterable: Iterable
    :return: the binary number.
    :rtype: int
    """
    return sum(1 << i for i, obj in enumerate(iterable) if obj)