
"""simple docstring"""

def      lowercase__    (       lowerCAmelCase					:       list[list[float]]			)			->   list[list[float]]:






    """simple docstring"""




    UpperCAmelCase          =       []
    for data in source_data:
        for i, el in enumerate(lowerCAmelCase			):
            if len(lowerCAmelCase			) < i + 1:
                data_lists.append([]			)
            data_lists[i].append(float(lowerCAmelCase			)			)
    return data_lists




def      lowercase__    (       lowerCAmelCase					:       list[list[float]]			,					lowerCAmelCase					:       list[int]			)			->   list[list[float]]:






    """simple docstring"""




    UpperCAmelCase          =       []
    for dlist, weight in zip(lowerCAmelCase			,					lowerCAmelCase			):
        UpperCAmelCase          =       min(lowerCAmelCase			)
        UpperCAmelCase          =       max(lowerCAmelCase			)

        UpperCAmelCase          =       []
        # for weight 0 score is 1 - actual score
        if weight == 0:
            for item in dlist:
                try:
                    score.append(1 - ((item - mind) / (maxd - mind))			)
                except ZeroDivisionError:
                    score.append(1			)

        elif weight == 1:
            for item in dlist:
                try:
                    score.append((item - mind) / (maxd - mind)			)
                except ZeroDivisionError:
                    score.append(0			)

        # weight not 0 or 1
        else:
            UpperCAmelCase          =       F"Invalid weight of {weight:f} provided"
            raise ValueError(lowerCAmelCase			)

        score_lists.append(lowerCAmelCase			)

    return score_lists




def      lowercase__    (       lowerCAmelCase					:       list[list[float]]			)			->   list[float]:






    """simple docstring"""




    UpperCAmelCase          =       [0 for i in range(len(score_lists[0]			)			)]

    for slist in score_lists:
        for j, ele in enumerate(lowerCAmelCase			):
            UpperCAmelCase          =       final_scores[j] + ele

    return final_scores







def      lowercase__    (       lowerCAmelCase					:       list[list[float]]			,					lowerCAmelCase					:       list[int]			)			->   list[list[float]]:






    """simple docstring"""




    UpperCAmelCase          =       get_data(lowerCAmelCase			)
    UpperCAmelCase          =       calculate_each_score(lowerCAmelCase			,					lowerCAmelCase			)
    UpperCAmelCase          =       generate_final_scores(lowerCAmelCase			)

    # append scores to source data
    for i, ele in enumerate(lowerCAmelCase			):
        source_data[i].append(lowerCAmelCase			)

    return source_data





"""simple docstring"""

from math import ceil, sqrt




def      lowercase__    (       lowerCAmelCase					:       int = 1_000_000			)			->   int:






    """simple docstring"""




    UpperCAmelCase          =       0

    for outer_width in range(3			,					(limit // 4) + 2			):
        if outer_width**2 > limit:
            UpperCAmelCase          =       max(ceil(sqrt(outer_width**2 - limit			)			)			,					1			)
        else:
            UpperCAmelCase          =       1
        if (outer_width - hole_width_lower_bound) % 2:
            hole_width_lower_bound += 1

        answer += (outer_width - hole_width_lower_bound - 2) // 2 + 1

    return answer


if __name__ == "__main__":
   print(F'{solution() = }')



