What's your ID?
You must have heard the name of Metropolitan University. As soon as a student get 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 very 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. 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
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.
Now your task is to write a program that prints the name of the department and the academic year of students from given ID numbers.
The first line contains a single integer N (1 ≤ N ≤ 1000).
The next N lines contain N ID numbers in “XXX-XXX-XXX” format.
Print N lines of output with the name of the department and academic year.
3 131-115-081 171-116-005 162-115-144
CSE Spring 2013 BBA Spring 2017 CSE Summer 2016