
    Given the current number of daily patient appointments, determine the smallest scheduling block size (which must be a power of 2) that can accommodate all appointments while maintaining optimal time slot distribution. This scheduling block size should be greater than or equal to the current appointment count to ensure efficient resource allocation and minimize scheduling gaps.
    

    
def next_power_of_2(n):
    """
    Given the current number of daily patient appointments, determine the smallest scheduling block size (which must be a power of 2) that can accommodate all appointments while maintaining optimal time slot distribution. This scheduling block size should be greater than or equal to the current appointment count to ensure efficient resource allocation and minimize scheduling gaps.
    

    """
def next_power_of_2(n):
    """
    Given the current number of daily patient appointments, determine the smallest scheduling block size (which must be a power of 2) that can accommodate all appointments while maintaining optimal time slot distribution. This scheduling block size should be greater than or equal to the current appointment count to ensure efficient resource allocation and minimize scheduling gaps.
    

    """
    if n and (not n & n - 1):
        return n
    count = 0
    while n != 0:
        n >>= 1
        count += 1
    return 1 << count