結果

問題 No.1692 Expectations
ユーザー ZZZZZZ
提出日時 2021-10-01 21:50:27
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 211 ms / 2,000 ms
コード長 1,676 bytes
コンパイル時間 292 ms
コンパイル使用メモリ 86,748 KB
実行使用メモリ 158,668 KB
最終ジャッジ日時 2023-09-26 17:01:30
合計ジャッジ時間 4,909 ms
ジャッジサーバーID
(参考情報)
judge12 / judge13
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 135 ms
76,972 KB
testcase_01 AC 134 ms
77,220 KB
testcase_02 AC 136 ms
76,916 KB
testcase_03 AC 135 ms
76,972 KB
testcase_04 AC 132 ms
76,824 KB
testcase_05 AC 134 ms
76,824 KB
testcase_06 AC 132 ms
76,828 KB
testcase_07 AC 138 ms
76,620 KB
testcase_08 AC 134 ms
76,960 KB
testcase_09 AC 131 ms
77,032 KB
testcase_10 AC 164 ms
94,224 KB
testcase_11 AC 163 ms
94,160 KB
testcase_12 AC 135 ms
76,968 KB
testcase_13 AC 136 ms
76,648 KB
testcase_14 AC 141 ms
80,336 KB
testcase_15 AC 177 ms
109,800 KB
testcase_16 AC 139 ms
80,708 KB
testcase_17 AC 157 ms
95,496 KB
testcase_18 AC 142 ms
83,588 KB
testcase_19 AC 205 ms
132,380 KB
testcase_20 AC 179 ms
119,660 KB
testcase_21 AC 211 ms
158,668 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys
from bisect import *
from collections import deque
#from functools import *
#from fractions import Fraction as f
from copy import *	
from heapq import *
from math import sqrt,ceil,gcd
from itertools import permutations as prm,product
from random import *
def eprint(*args):
    print(*args, file=sys.stderr)
zz=1
 
sys.setrecursionlimit(10**5)
if zz:
	input=sys.stdin.readline
else:	
	sys.stdin=open('input.txt', 'r')
	sys.stdout=open('all.txt','w')
di=[[-1,0],[1,0],[0,1],[0,-1]]

def fori(n):
	return [fi() for i in range(n)]	
def inc(d,c,x=1):
	d[c]=d[c]+x if c in d else x
def ii():
	return input().rstrip()	
def li():
	return [int(xx) for xx in input().split()]
def fli():
	return [float(x) for x in input().split()]	
def dadd(d,p,val):
	if p in d:
		d[p].append(val)
	else:
		d[p]=[val]		
def gi():	
	return [xx for xx in input().split()]
def gtc(tc,*ans):
	print("Case #"+str(tc)+":",*ans)	
def cil(n,m):
	return n//m+int(n%m>0)	
def fi():
	return int(input())
def pro(a): 
	return reduce(lambda a,b:a*b,a)		
def swap(a,i,j): 
	a[i],a[j]=a[j],a[i]	
def bits(i,n):
	p=bin(i)[2:]
	return (n-len(p))*"0"+p	
def prec(a,pre):
	for i in a:
		pre.append(pre[-1]+i)
	pre.pop(0)	
def YN(flag):
	print("YES" if flag else "NO")	
def si():
	return list(input().rstrip())	
def mi():
	return 	map(int,input().split())			
def gh():
	sys.stdout.flush()
def isvalid(i,j,n,m):
	return 0<=i<n and 0<=j<m 
def bo(i):
	return ord(i)-ord('a')	
def graph(n,m):
	for i in range(m):
		x,y=mi()
		a[x].append(y)
		a[y].append(x)


t=1
INF=10**18
uu=t
mod=10**9+7
				
			


while t>0:
	t-=1
	n,m=mi()
	a=li()
	mn=0
	if n==m and len(set(a))==1:
		mn=1
	mx=len(set(a))
	print(mx,mn)	 
	
0