You must have heard the name of Metropolitan University. As soon as a student gets admitted there, the university provides him/her a nine digits ID (e.g. 131-115-100).
If you notice carefully, you will find that this is not just a random number. The first two digits define the year of admission, and the third digit indicates the term of admission. 1 for Spring, 2 for Summer and 3 for Autumn. The next three digits indicate the name of the department.
115 for CSE
141 for EEE
116 for BBA
117 for LLB
114 for English and
111 for Economics
The rest of the digits indicate the roll number of the student.
For instance, Nasif’s ID is 171-115-249. Here 171 means his academic year is Spring 2017. 115 means he is a student of CSE, and 249 is his class roll.
Your task is to write a program that prints the department's name and students’ academic year from given ID numbers.
The first line contains a single integer ().
The next lines contain ID numbers in "XXX-XXX-XXX" format.
Print lines of output with the name of the department and academic year.
Input | Output |
---|---|
3 131-115-081 171-116-005 162-115-144 | CSE Spring 2013 BBA Spring 2017 CSE Summer 2016 |