School holidays come in Berland. The holidays are going to continue for n days. The students of school №N are having the time of their lives and the IT teacher Marina Sergeyevna, who has spent all the summer busy checking the BSE (Berland State Examination) results, has finally taken a vacation break! Some people are in charge of the daily watering of flowers in shifts according to the schedule. However when Marina Sergeyevna was making the schedule, she was so tired from work and so lost in dreams of the oncoming vacation that she perhaps made several mistakes. In fact, it is possible that according to the schedule, on some days during the holidays the flowers will not be watered or will be watered multiple times. Help Marina Sergeyevna to find a mistake.

Input

The first input line contains two numbers n and m (1 ≤ n, m ≤ 100) — the number of days in Berland holidays and the number of people in charge of the watering respectively. The next m lines contain the description of the duty schedule. Each line contains two integers ai and bi (1 ≤ ai ≤ bi ≤ n), meaning that the i-th person in charge should water the flowers from the ai-th to the bi-th day inclusively, once a day. The duty shifts are described sequentially, i.e. bi ≤ ai + 1 for all i from 1 to n - 1 inclusively. 

Output

Print "OK" (without quotes), if the schedule does not contain mistakes. Otherwise you have to find the minimal number of a day when the flowers will not be watered or will be watered multiple times, and output two integers — the day number and the number of times the flowers will be watered that day.

Examples

Input

10 5
1 2
3 3
4 6
7 7
8 10


Output

OK


Input

10 5
1 2
2 3
4 5
7 8
9 10


Output

2 2


Input

10 5
1 2
3 3
5 7
7 7
7 10


Output

4 0

Note

Keep in mind that in the second sample the mistake occurs not only on the second day, but also on the sixth day, when nobody waters the flowers. However, you have to print the second day, i.e. the day with the minimal number.

Source: codeforces | Difficulty: EASY
Tags: Implementation


Solutions:
(n, m) = map(int, input().split())
c = [0] * n
for i in range(m):
	(a, b) = map(int, input().split())
	for j in range(a - 1, b):
		c[j] += 1
for i in range(n):
	if c[i] != 1:
		print(i + 1, c[i])
		exit()
print('OK')


TN = 1

def solution():
	(n, m) = map(int, input().split())
	ans = [0 for i in range(n)]
	cur = -1
	ind = -1
	for i in range(m):
		(a, b) = map(int, input().split())
		for j in range(a - 1, b):
			if ans[j] == 1 and cur == -1:
				cur = j
			ans[j] += 1
	if ans.count(0) > 0:
		ind = ans.index(0)
	if cur == -1 and ind == -1:
		print('OK')
		exit()
	if cur < ind:
		if cur != -1:
			print(cur + 1, ans[cur])
		else:
			print(ind + 1, ans[ind])
	elif ind != -1:
		print(ind + 1, ans[ind])
	else:
		print(cur + 1, ans[cur])
while TN != 0:
	solution()
	TN -= 1


(n, m) = map(int, input().split())
Ln = [0] * n
while m != 0:
	(a, b) = map(int, input().split())
	for i in range(a, b + 1):
		Ln[i - 1] += 1
	m -= 1
for i in range(0, len(Ln)):
	if Ln[i] == 0:
		print(i + 1, 0)
		exit(0)
	elif Ln[i] > 1:
		print(i + 1, Ln[i])
		exit(0)
print('OK')
exit(0)


(n, m) = map(int, input().split())
a = [0] * (n + 1)
for i in range(m):
	(x, y) = map(int, input().split())
	for j in range(x, y + 1):
		a[j] += 1
for i in range(1, n + 1):
	if a[i] > 1 or a[i] == 0:
		print(i, a[i])
		exit(0)
print('OK')


a = [int(j) for j in input().split()]
n = a[0]
m = a[1]
count = 0
b = [0 for i in range(m)]
for i in range(m):
	b[i] = [int(j) for j in input().split()]
if b[0][0] != 1:
	print(1, 0)
else:
	for i in range(m - 1):
		if b[i][1] == b[i + 1][0]:
			count = 2
			for k in range(i + 2, m):
				if b[k][0] == b[i][1]:
					count += 1
			print(b[i][1], count)
			break
		elif b[i + 1][0] - b[i][1] > 1:
			print(b[i][1] + 1, 0)
			count = 1
			break
	if not count:
		if b[m - 1][1] != n:
			print(b[m - 1][1] + 1, 0)
		else:
			print('OK')


(n, m) = input().split()
(n, m) = (int(n), int(m))
out = False
d = [0 for i in range(0, n + 2)]
for i in range(0, m):
	(a, b) = input().split()
	(a, b) = (int(a), int(b))
	d[a] += 1
	d[b + 1] -= 1
for i in range(1, n + 1):
	count = sum(d[0:i + 1])
	if count != 1:
		print(i, count)
		out = True
		break
if not out:
	print('OK')


str_in = input()
num = [int(x) for x in str_in.split()]
n = int(num[0])
m = int(num[1])
c = 0
List = []
key = 0
for c in range(m):
	str_in = input()
	num = [int(x) for x in str_in.split()]
	List.append(num)
List2 = [0 for x in range(0, n + 1)]
for i in range(m):
	l = List[i][0]
	r = List[i][1]
	for y in range(l, r + 1):
		List2[y] = List2[y] + 1
for i in range(1, n + 1):
	if List2[i] != 1:
		key = 1
		print(i, List2[i])
		break
if key == 0:
	print('OK')


a = input().split()
s = {}
for i in range(int(a[0])):
	s[i + 1] = 0
for i in range(int(a[1])):
	d = input().split()
	for j in range(int(d[0]), int(d[1]) + 1):
		s[j] += 1
for i in s:
	if s[i] != 1:
		print(i, s[i])
		exit()
print('OK')


def parsing(dual):
	a_b = dual.split()
	a = int(a_b[0])
	b = int(a_b[1])
	return (a, b)

def creatTable(rows):
	table = []
	index = 1
	while index <= rows:
		ai_bi = parsing(input())
		table.append(ai_bi)
		index += 1
	return table

class schedule:

	def __init__(self, n_m):
		days_people = parsing(n_m)
		self.days = days_people[0]
		self.people = days_people[1]
		self.table = creatTable(self.people)
		self.check2()

	def check2(self):
		self.fullTable = []
		for row in self.table:
			ai = row[0]
			bi = row[1]
			i = ai
			while i <= bi:
				self.fullTable.append(i)
				i += 1
		self.optimalTable = []
		i = 1
		while i <= self.days:
			self.optimalTable.append(i)
			i += 1
		for optimal in self.optimalTable:
			goodSoFar = True
			if self.fullTable.count(optimal) == 1:
				continue
			else:
				day = optimal
				times = self.fullTable.count(optimal)
				goodSoFar = False
				break
		if goodSoFar == True:
			print('OK')
		else:
			print(day, times)
schedule1 = schedule(input())


(n, m) = [int(j) for j in input().split()]
status = n * [0]
for j in range(m):
	(a, b) = [int(j) for j in input().split()]
	for k in range(a - 1, b):
		status[k] += 1
output = 'OK'
for j in range(n):
	if status[j] != 1:
		output = str(j + 1) + ' ' + str(status[j])
		break
print(output)


(n, m) = map(int, input().split())
lis = []
lis.append([0, 0])
lis.append([n + 1, n + 1])
c = 0
ans = 0
for i in range(m):
	(a, b) = map(int, input().split())
	lis.append([a, b])
lis.sort()
for i in range(m + 1):
	if lis[i][1] + 1 < lis[i + 1][0]:
		print(lis[i][1] + 1, '0')
		exit()
	elif lis[i][1] >= lis[i + 1][0]:
		ans = lis[i + 1][0]
		break
if ans == 0:
	print('OK')
	exit()
for j in range(m + 1):
	if lis[j][0] <= ans and lis[j][1] >= ans:
		c += 1
print(ans, c)


(n, m) = map(int, input().split())
a = [0] * n
for i in range(m):
	(l, r) = map(int, input().split())
	for j in range(l, r + 1):
		a[j - 1] += 1
if sum(a) == n and (not 0 in a):
	print('OK')
else:
	for i in range(n):
		if a[i] != 1:
			print(i + 1, a[i])
			exit()


p = input()
p_lst = p.split()
Holiday = int(p_lst[0])
people = int(p_lst[1])
m = []
for i in range(Holiday):
	m.append(0)
for o in range(people):
	day = input()
	d_lst = day.split()
	d1 = int(d_lst[0]) - 1
	d2 = int(d_lst[1])
	for j in range(d1, d2):
		m[j] += 1
t = 1
for i in m:
	if i != 1:
		print(m.index(i) + 1, i)
		break
if m.count(1) == Holiday:
	print('OK')


(n, m) = map(int, input().split())
ar = [0 for _ in range(n)]
for _ in range(m):
	(a, b) = map(int, input().split())
	for j in range(a - 1, b):
		ar[j] += 1
for e in range(n):
	if ar[e] != 1:
		print(e + 1, ar[e])
		break
else:
	print('OK')


[n, m] = map(int, input().split())
st = [0] * (n + 1)
for i in range(m):
	[a, b] = map(int, input().split())
	for j in range(a, b + 1):
		st[j] += 1
k = 0
for i in range(1, n + 1):
	if st[i] != 1:
		k = i
		break
if k != 0:
	print('%d %d' % (k, st[k]))
else:
	print('OK')


import sys
(n, m) = map(int, input().split())
c = [0 for i in range(n + 1)]
for i in range(m):
	(x, y) = map(int, input().split())
	for j in range(x, y + 1):
		c[j] += 1
for i in range(1, n + 1):
	if c[i] != 1:
		print(str(i) + ' ' + str(c[i]))
		exit(0)
print('OK')


(n, m) = map(int, input().split())
a = [0] * n
for i in range(m):
	(x, y) = map(int, input().split())
	for j in range(x - 1, y):
		a[j] += 1
for i in range(n):
	if a[i] != 1:
		print(i + 1, a[i])
		break
else:
	print('OK')


import os
import sys
from io import BytesIO, IOBase
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))

def input():
	return sys.stdin.readline().rstrip('\r\n')
(n, m) = map(int, input().split())
c = [0] * n
for i in range(m):
	(a, b) = map(int, input().split())
	for j in range(a - 1, b):
		c[j] += 1
for i in range(n):
	if c[i] != 1:
		print(i + 1, c[i])
		exit()
print('OK')


mod = 1000000007
ii = lambda : int(input())
si = lambda : input()
dgl = lambda : list(map(int, input()))
f = lambda : map(int, input().split())
il = lambda : list(map(int, input().split()))
ls = lambda : list(input())
(n, k) = f()
l = [0] * (n + 2)
for _ in range(k):
	(a, b) = f()
	l[a] += 1
	l[b + 1] -= 1
for i in range(1, n + 2):
	l[i] = l[i] + l[i - 1]
for i in range(1, n + 1):
	if l[i] == 0 or l[i] > 1:
		exit(print(i, l[i]))
print('OK')


(n, m) = [int(i) for i in input().split()]
days = [0] * n
for i in range(m):
	(s, f) = [int(k) for k in input().split()]
	for k in range(f - s + 1):
		days[s - 1 + k] += 1
m = -1
for i in range(n):
	if days[i] != 1:
		m = i + 1
		n = days[i]
		break
if m == -1:
	print('OK\n')
else:
	print('%d %d\n' % (m, n))


(n, m) = map(int, input().split())
cnt = [0] * (n + 1)
for i in range(1, m + 1):
	(a, b) = map(int, input().split())
	for i in range(a, b + 1):
		cnt[i] += 1
f = 0
for i in range(1, n + 1):
	if cnt[i] == 0 or cnt[i] > 1:
		print(i, cnt[i])
		f = 1
		break
if f == 0:
	print('OK')


R = lambda : list(map(int, input().split()))
(n, m) = R()
inps = []
for x in range(m):
	inps.append(R())
dArray = [0 for i in range(n)]
for x in inps:
	start = x[0]
	end = x[1]
	for i in range(start, end + 1):
		dArray[i - 1] += 1
ans = 'OK'
for i in range(n):
	if dArray[i] == 1:
		continue
	else:
		ans = str(i + 1) + ' ' + str(dArray[i])
		break
print(ans)


import sys
(n, m) = map(int, input().split())
list1 = []
list1 = []
for i in range(m):
	(a, b) = map(int, input().split())
	list1.extend([int(i) for i in range(a, b + 1)])
for i in range(1, n + 1):
	t = list1.count(i)
	if t != 1:
		print(i, t)
		sys.exit()
print('OK')


table = {}
(n, m) = [int(k) for k in input().split()]
for i in range(1, n + 1):
	table[i] = 0
a = []
b = []
check = 0
for i in range(m):
	x = [int(k) for k in input().split()]
	a.append(x[0])
	b.append(x[1])
for i in range(m):
	for j in range(a[i], b[i] + 1):
		table[j] += 1
for i in range(1, n + 1):
	if table[i] != 1:
		amount = table[i]
		date = i
		check = 1
		break
if check == 1:
	print(date, amount)
else:
	print('OK')


(n, m) = map(int, input().split())
a = [0] * (n + 1)
for _ in range(m):
	(L, R) = map(int, input().split())
	for x in range(L, R + 1):
		a[x] += 1
x = 0
for i in range(1, n + 1):
	if a[i] != 1:
		x = i
		break
print('OK') if x == 0 else print(x, a[x])


from math import ceil, floor
from sys import stdin, stdout
(a, b) = map(int, stdin.readline().split())
gh = [0] * (a + 1)
gh[0] = 10000
co = 0
co1 = 0
for i in range(b):
	(u, v) = map(int, stdin.readline().split())
	if min(gh[:u]) == 0:
		if co1 == 0:
			co1 = gh[:u].index(0)
	for j in range(u, v + 1):
		gh[j] += 1
		if gh[j] > 1 and co == 0:
			co = j
if co and co1:
	if co < co1:
		print(co, gh[co])
	else:
		print(co1, 0)
elif co:
	print(co, gh[co])
elif co1:
	print(co1, 0)
else:
	for i in range(1, a + 1):
		if gh[i] == 0:
			exit(print(i, 0))
	stdout.write('OK')


(holidays, people) = map(int, input().split())
water = [0] * holidays
for p in range(people):
	(start, end) = map(int, input().split())
	for i in range(start, end + 1):
		water[i - 1] += 1
f = 1
for (i, w) in enumerate(water):
	if w != 1:
		print(i + 1, end=' ')
		print(w)
		f = 0
		break
if f:
	print('OK')


I = lambda : map(int, input().split())
(n, m) = I()
X = [0] * n
for _ in range(m):
	(a, b) = I()
	for i in range(a - 1, b):
		X[i] += 1
for i in range(n):
	if X[i] != 1:
		print(i + 1, X[i])
		break
else:
	print('OK')


def main():
	(n, m) = map(int, input().split(' '))
	days = [0 for _ in range(n + 1)]
	for i in range(m):
		(sta_day, end_day) = map(int, input().split(' '))
		if sta_day == end_day:
			days[sta_day] += 1
		else:
			for j in range(sta_day, end_day + 1):
				days[j] += 1
	for i in range(1, len(days)):
		if days[i] != 1:
			return (i, days[i])
	return 'OK'
res = main()
if res == 'OK':
	print(res)
else:
	print(res[0], res[1])


def getquanto(v, m, cs):
	q = 0
	day = v[cs + 1][0]
	for c in range(cs, m):
		if v[c][0] <= day:
			q += 1
	return q

def corr(v, m, n):
	if v[0][0] > 1:
		return (0, 1, 0)
	for c in range(m - 1):
		if v[c + 1][0] - v[c][1] <= 0:
			return (0, v[c + 1][0], getquanto(v, m, c))
		elif v[c + 1][0] - v[c][1] > 1:
			return (0, v[c][1] + 1, 0)
	if v[m - 1][1] < n:
		return (0, v[m - 1][1] + 1, 0)
	return (1, 0, 0)
(n, m) = map(int, input().split(' '))
v = []
for c in range(m):
	(a, b) = map(int, input().split(' '))
	v += [(a, b)]
(ok, day, quanto) = corr(v, m, n)
if ok:
	print('OK')
else:
	print('{} {}'.format(day, quanto))


import math
(n, m) = map(int, input().strip().split(' '))
i = 1
f = 0
c = 0
for j in range(m):
	(a1, b1) = map(int, input().strip().split(' '))
	if j == 0:
		if a1 != 1:
			print('1 0')
			f = 1
			break
		else:
			i = b1
	elif f == 2:
		if i >= a1 and i <= b1:
			c += 1
	elif a1 == i + 1:
		i = b1
	elif a1 <= i:
		f = 2
		i = a1
		c = 2
	else:
		print(i + 1, 0, end=' ')
		f = 1
		break
	if j == m - 1 and b1 != n:
		if c == 0:
			print(b1 + 1, 0, end=' ')
			f = 1
			break
if f == 0:
	print('OK')
elif f == 2:
	print(i, c, end=' ')


(n, m) = map(int, input().split())
jel = [0] * (n + 1)
for _ in range(m):
	(a, b) = map(int, input().split())
	for t in range(a, b + 1):
		jel[t] += 1
i = 1
while i <= n and jel[i] == 1:
	i += 1
if i > n:
	print('OK')
else:
	print(i, jel[i])


import sys
import math
import collections
import heapq
import decimal
input = sys.stdin.readline
(n, m) = (int(i) for i in input().split())
l = []
for i in range(m):
	(a, b) = (int(i) for i in input().split())
	l += [a, b]
if l[0] != 1:
	print(1, 0)
else:
	c = 1
	k = -1
	for i in range(2, 2 * m, 2):
		if l[i] <= l[i - 1]:
			k = l[i]
			c = 0
			break
		elif l[i] > l[i - 1] + 1:
			k = l[i - 1] + 1
			c = -1
			break
	if c == 1:
		if l[-1] != n:
			print(l[-1] + 1, 0)
		else:
			print('OK')
	elif c == -1:
		print(k, 0)
	else:
		c1 = 0
		for i in range(0, 2 * m, 2):
			if l[i] <= k and l[i + 1] >= k:
				c1 += 1
		print(k, c1)


(a, b) = map(int, input().split())
z = [0] * (a + 1)
z[0] = 10000
p = 0
p1 = 0
for i in range(b):
	(u, v) = map(int, input().split())
	if min(z[:u]) == 0:
		if p1 == 0:
			p1 = z[:u].index(0)
	for j in range(u, v + 1):
		z[j] += 1
		if z[j] > 1 and p == 0:
			p = j
if p and p1:
	if p < p1:
		print(p, z[p])
	else:
		print(p1, 0)
elif p:
	print(p, z[p])
elif p1:
	print(p1, 0)
else:
	for i in range(1, a + 1):
		if z[i] == 0:
			exit(print(i, 0))
	print('OK')


(n, m) = list(map(int, input().split(' ')))
current = 0
count = 0
true = False
toPrint = 'OK'
for line in range(m):
	(a, b) = list(map(int, input().split(' ')))
	if a == current + 1:
		current = b
	elif a > current + 1:
		current += 1
		true = True
		break
	else:
		count = 2
		for line2 in range(line + 1, m):
			(a, b) = list(map(int, input().split(' ')))
			if a > current:
				break
			elif a == current:
				count += 1
			else:
				(current, count) = (a, 2)
		true = True
		break
if true:
	print(current, count)
elif current == n:
	print('OK')
else:
	print(current + 1, 0)


(n, m) = map(int, input().split())
hols = []
for i in range(m):
	hols.append(list(map(int, input().split())))
days = []
for (a, b) in hols:
	days.append(list(range(a, b + 1)))
days = sum(days, [])
res = []
for x in days:
	if days.count(x) > 1:
		res.append(x)
		break
for i in range(1, n + 1):
	if days.count(i) == 0:
		res.append(i)
		break
if res:
	day = min(res)
	print(day, days.count(day))
else:
	print('OK')


(n, m) = map(int, input().split())
days = [0] * (n + 1)
for i in range(m):
	(ai, bi) = map(int, input().split())
	while ai <= bi:
		days[ai] += 1
		ai += 1
flag = True
for i in range(1, n + 1):
	if days[i] != 1:
		print(i, days[i])
		flag = False
		break
if flag:
	print('OK')


(num_days, num_spans) = map(int, input().split())
spans = [list(map(int, input().split())) for i in range(num_spans)]
counts = [0 for i in range(num_days + 1)]
for (a, b) in spans:
	for day in range(a, b + 1):
		counts[day] += 1
for day in range(1, num_days + 1):
	if counts[day] != 1:
		print(day, counts[day])
		import sys
		sys.exit()
print('OK')


(n, m) = [int(i) for i in input().split()]
lst = [0] * n
for i in range(m):
	(a, b) = [int(x) for x in input().split()]
	for j in range(a - 1, b):
		lst[j] += 1
for i in range(n):
	if lst[i] != 1:
		print(i + 1, lst[i])
		exit()
print('OK')


import sys
import math
import itertools
import functools
import collections
import operator
import fileinput

def ii():
	return int(input())

def mi():
	return map(int, input().split())

def li():
	return list(map(int, input().split()))

def lcm(a, b):
	return abs(a * b) // math.gcd(a, b)

def revn(n):
	return str(n)[::-1]

def dd():
	return collections.defaultdict(int)

def ddl():
	return collections.defaultdict(list)

def sieve(n):
	if n < 2:
		return list()
	prime = [True for _ in range(n + 1)]
	p = 3
	while p * p <= n:
		if prime[p]:
			for i in range(p * 2, n + 1, p):
				prime[i] = False
		p += 2
	r = [2]
	for p in range(3, n + 1, 2):
		if prime[p]:
			r.append(p)
	return r

def divs(n, start=2):
	r = []
	for i in range(start, int(math.sqrt(n) + 1)):
		if n % i == 0:
			if n / i == i:
				r.append(i)
			else:
				r.extend([i, n // i])
	return r

def divn(n, primes):
	divs_number = 1
	for i in primes:
		if n == 1:
			return divs_number
		t = 1
		while n % i == 0:
			t += 1
			n //= i
		divs_number *= t

def prime(n):
	if n == 2:
		return True
	if n % 2 == 0 or n <= 1:
		return False
	sqr = int(math.sqrt(n)) + 1
	for d in range(3, sqr, 2):
		if n % d == 0:
			return False
	return True

def convn(number, base):
	newnumber = 0
	while number > 0:
		newnumber += number % base
		number //= base
	return newnumber

def cdiv(n, k):
	return n // k + (n % k != 0)
(n, m) = mi()
arr = [0] * n
for _ in range(m):
	(a, b) = mi()
	for i in range(a - 1, b):
		arr[i] += 1
for i in range(n):
	if arr[i] != 1:
		print(i + 1, arr[i])
		break
else:
	print('OK')


(n, m) = map(int, input().split())
c = [[0, 0]]
for i in range(m):
	(a, b) = map(int, input().split())
	c.append([a, b])
l = 0
z = 0
c.append([n + 1, n + 1])
for i in range(1, len(c)):
	if c[i - 1][1] == c[i][0]:
		k = c[i - 1][1]
		break
	if c[i][0] - c[i - 1][1] > 1:
		k = c[i - 1][1] + 1
		z += 1
		break
try:
	if z == 1:
		print(k, 0)
	else:
		for i in range(len(c)):
			if k == c[i][1] and k == c[i][0]:
				l += 1
			elif k == c[i][1]:
				l += 1
			elif k == c[i][0]:
				l += 1
		print(k, l)
except:
	print('OK')