1️⃣ 최소, 최대

N = int(input())
list_ = list(map(int, input().split()))
min = max = list_[0]

for i in range(N):
	if min > list_[i]:
		min = list_[i]
	if max < list_[i]:
		max = list_[i]

print(min, max)

2️⃣ 최댓값

numList = []
max = 0; index = 0

for i in range(9):
	numList.append(int(input()))
	if max < numList[i]:
		max = numList[i]
		index = i+1

print(max, index, sep="\\n")

3️⃣ 숫자의 개수

num = [0]*10
A = int(input()); B =int(input()); C = int(input())

resultList = list(map(int, str(A*B*C)))
for i in range(len(resultList)):
	num[resultList[i]] += 1

for i in range(10):
	print(num[i])
# list(map(lambda x: print(x), num))

4️⃣ 나머지

result = [0]*42
cnt = 0

for i in range(10):
	x = int(input())
	result[x%42] += 1

for i in range(42):
	if result[i] != 0:
		cnt += 1

print(cnt)

5️⃣ 평균