






'''simple docstring'''





import os


def 				snake_case__							(							):
    with open(os.path.dirname(UpperCAmelCase__       ) + "/grid.txt"       ) as f:
        lowerCAmelCase__   :Any      							=				[]  # noqa: E741
        for _ in range(2_0       ):
            l.append([int(UpperCAmelCase__       ) for x in f.readline().split()]       )

        lowerCAmelCase__   :List[str]      							=				0

        # right
        for i in range(2_0       ):
            for j in range(1_7       ):
                lowerCAmelCase__   :List[Any]      							=				l[i][j] * l[i][j + 1] * l[i][j + 2] * l[i][j + 3]
                if temp > maximum:
                    lowerCAmelCase__   :List[Any]      							=				temp

        # down
        for i in range(1_7       ):
            for j in range(2_0       ):
                lowerCAmelCase__   :List[str]      							=				l[i][j] * l[i + 1][j] * l[i + 2][j] * l[i + 3][j]
                if temp > maximum:
                    lowerCAmelCase__   :List[str]      							=				temp

        # diagonal 1
        for i in range(1_7       ):
            for j in range(1_7       ):
                lowerCAmelCase__   :List[str]      							=				l[i][j] * l[i + 1][j + 1] * l[i + 2][j + 2] * l[i + 3][j + 3]
                if temp > maximum:
                    lowerCAmelCase__   :Optional[int]      							=				temp

        # diagonal 2
        for i in range(1_7       ):
            for j in range(3    ,			2_0       ):
                lowerCAmelCase__   :Union[str, Any]      							=				l[i][j] * l[i + 1][j - 1] * l[i + 2][j - 2] * l[i + 3][j - 3]
                if temp > maximum:
                    lowerCAmelCase__   :Union[str, Any]      							=				temp
        return maximum


if __name__ == "__main__":
 print(solution())











def 				snake_case__							(							UpperCAmelCase							:  float    ,			UpperCAmelCase							:  list[float]       ):
    if discount_rate < 0:
        raise ValueError("Discount rate cannot be negative"       )
    if not cash_flows:
        raise ValueError("Cash flows list cannot be empty"       )
    lowerCAmelCase__   :List[Any]      							=				sum(
        cash_flow / ((1 + discount_rate) ** i) for i, cash_flow in enumerate(UpperCAmelCase       )       )
    return round(UpperCAmelCase    ,			ndigits=2       )


if __name__ == "__main__":
 import doctest

 doctest.testmod()



