All submissions for this problem are available.
Michael is planning to create a Social network similar to Facebook.
In his network there are two ways in which user can make friends:
1. Users can visit their friend's profile and visit their friend list and send friend request to anyone in the list.
2. Users can use search option and find random user and send them a request.But they won't use this method if the user can befriend another user by method 1.
If a user befriends another user by method 1, output "Type 1"
If a user befriends another user by method 2 , output "Type 2".
Note: A user can also view friends list of the friends of his/her friends.
First line contains single integer T denoting number of testcases
Next and final line containes names of two users who became friends.
Print Type 1 or Type 2 according to the way users became friends.
1 <= T <= 2*105
Chris and John became friends by random search. Same goes for John and Susan. But Chris is already friends with John, who is friends with Susan.
So Chris and Susan befriend each other by method 1.
|Time Limit:||1 - 2 sec|
|Source Limit:||50000 Bytes|
|Languages:||C, CPP14, JAVA, PYTH, PYTH 3.6|
Fetching successful submissions