結果

問題 No.112 ややこしい鶴亀算
ユーザー tookunn_1213
提出日時 2015-05-30 19:12:37
言語 Python2
(2.7.18)
結果
WA  
実行時間 -
コード長 151 bytes
コンパイル時間 455 ms
コンパイル使用メモリ 6,912 KB
実行使用メモリ 6,272 KB
最終ジャッジ日時 2024-07-06 12:46:55
合計ジャッジ時間 997 ms
ジャッジサーバーID
(参考情報)
judge5 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 2
other WA * 23
権限があれば一括ダウンロードができます

ソースコード

diff #

N = int(raw_input())
a = map(int,raw_input().split())
s = sum(a)
t,k = 0,0
while s > 0:
	if s >= 4:
		s -= 4
		k +=1
	else:
		s -= 2
		t += 1
print k,t
0