# Serence

## 洛谷入门题 - 3

### P1075

a = int(input())
b = 0

for i in range(2,a // 2 + 1):
if a % i == 0:
print(a // i)
break


### P1598

1、直接输出
2、将数据存储到二维列表后输出

string = ""
for i in range(0,4):
string += input().lower()

result = []

for i in range(0,26):
a = chr(i+ord("a"))
index = 0
temp = 0
while True:
x = string.find(a,index)
if x != -1:
temp += 1
index = x + 1
else:
break

result.append(temp)

t = max(result)
ind = 0
cishu = 0

while max(result) != 0:
a = max(result)
index = result.index(a)
if a != t:
for i in range(0,t - a):
print("")
for i in range(0,index):
print(" ",end=" ")
else:
if cishu != 0:
print(" ",end="")
else:
print("  ",end="")
cishu = 1
for i in range(0,index - ind - 1):
print(" ",end=" ")

print("*",end="")

t = a
result[index] -= 1
ind = index

print("")
for i in range(0,25):
print(chr(ord("A") + i) + " ", end = "")
print("Z",end="")


### P1914

a = int(input())
s = input()
ss = ""

for i in range(0,len(s)):
t = ord(s[i]) - ord("a")
t += a
t = t % 26
ss = ss + chr(t + ord("a"))

print(ss)


### P2141

a = int(input())
b = input().split()
count = 0
c = []

for i in range(0,a):
b[i] = int(b[i])

for i in range(0,len(b)):
for k in range(i + 1,a):
temp = b[i] + b[k]
if temp in b:
if temp not in c:
count += 1
c.append(temp)

print(count)


### P1308

w = input().lower()
s = input().lower()

count = 0
index = -1
t = 0

while True:
i = s.find(w,t)
if i != -1:
qian = s[i - 1] if (i - 1) >= 0 else " "
hou = s[i + len(w)] if (i + 1) <= len(s) - 1 else " "
if qian == " " and hou == " ":
count += 1
if count == 1:
index = i
t = i + 1
else:
break

if count > 0:
print(str(count) + " " + str(index))
else:
print(-1)


EOF