Start: Apr, 17, 2017 10:00:00
Python程序设计基础培训第三次作业
End: Apr, 23, 2017 14:00:00
Time elapsed:
Time remaining:

Problem_ID: A
Result: Accepted
Time: 146ms
Memory: 23552kB
Author: 13858550327
In contest: 1087

#!usr/bin/python
#coding=utf-8
dd={0:9,1:6,2:5,3:5,4:5,5:5,6:6}
import datetime
T = input()
for i in range(T):
	y=input()
	d=datetime.datetime(y,5,1).weekday()
	print dd[d]