




'''simple docstring'''






import os

def 			__lowerCAmelCase					(    ):
			with open(os.path.dirname(snake_case__						) + "/grid.txt"						) as f:
						__UpperCamelCase      :			Tuple									=   []  # noqa: E741
						for _ in range(20						):
									l.append([int(snake_case__						) for x in f.readline().split()]						)

						__UpperCamelCase      :			Dict									=   0

						# right
						for i in range(20						):
									for j in range(17						):
												__UpperCamelCase      :			Any									=   l[i][j] * l[i][j + 1] * l[i][j + 2] * l[i][j + 3]
												if temp > maximum:
															__UpperCamelCase      :			Dict									=   temp

        # down
						for i in range(17						):
									for j in range(20						):
												__UpperCamelCase      :			Tuple									=   l[i][j] * l[i + 1][j] * l[i + 2][j] * l[i + 3][j]
												if temp > maximum:
															__UpperCamelCase      :			List[str]									=   temp

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

        # diagonal 2
						for i in range(17						):
									for j in range(3					,      20						):
												__UpperCamelCase      :			Any									=   l[i][j] * l[i + 1][j - 1] * l[i + 2][j - 2] * l[i + 3][j - 3]
												if temp > maximum:
															__UpperCamelCase      :			List[str]									=   temp
						return maximum


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










'''simple docstring'''







from typing import TYPE_CHECKING

from ...file_utils import _LazyModule, is_tokenizers_available, is_torch_available
from ...utils import OptionalDependencyNotAvailable


lowerCAmelCase_					:    int      	=			{'configuration_gpt_neox': ['GPT_NEOX_PRETRAINED_CONFIG_ARCHIVE_MAP', 'GPTNeoXConfig']}

try:
					if not is_tokenizers_available():
										raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
					pass
else:
					lowerCAmelCase_					:    Optional[int]      	=			['GPTNeoXTokenizerFast']

try:
					if not is_torch_available():
										raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
					pass
else:
					lowerCAmelCase_					:    List[str]      	=			[
					    'GPT_NEOX_PRETRAINED_MODEL_ARCHIVE_LIST',
					    'GPTNeoXForCausalLM',
					    'GPTNeoXForQuestionAnswering',
					    'GPTNeoXForSequenceClassification',
					    'GPTNeoXForTokenClassification',
					    'GPTNeoXLayer',
					    'GPTNeoXModel',
					    'GPTNeoXPreTrainedModel',
					]


if TYPE_CHECKING:
					from .configuration_gpt_neox import GPT_NEOX_PRETRAINED_CONFIG_ARCHIVE_MAP, GPTNeoXConfig

					try:
										if not is_tokenizers_available():
															raise OptionalDependencyNotAvailable()
					except OptionalDependencyNotAvailable:
										pass
					else:
										from .tokenization_gpt_neox_fast import GPTNeoXTokenizerFast

					try:
										if not is_torch_available():
															raise OptionalDependencyNotAvailable()
					except OptionalDependencyNotAvailable:
										pass
					else:
										from .modeling_gpt_neox import (
										    GPT_NEOX_PRETRAINED_MODEL_ARCHIVE_LIST,
										    GPTNeoXForCausalLM,
										    GPTNeoXForQuestionAnswering,
										    GPTNeoXForSequenceClassification,
										    GPTNeoXForTokenClassification,
										    GPTNeoXLayer,
										    GPTNeoXModel,
										    GPTNeoXPreTrainedModel,
										)


else:
					import sys

					lowerCAmelCase_					:    List[str]      	=			_LazyModule(__name__, globals()['__file__'], _import_structure, module_spec=__spec__)
