Ren has recently created a website, Ternary Search, which he intends on turning into the premier platform for competitive programmers to talk about anything.
In order to facilitate conversation between different users, Ren is working on a new feature called "friends". The feature will allow two distinct users to be friends. Ren is working on a prototype of this feature right now, so at present, all users are friends with Ren, and these are the only friendships present on the platform.
Including Ren, there are users on the platform. Ren eventually wants to track a metric which he calls the "lonely user" metric, which is a count of how many users have exactly one friend. With the prototype the way it is now, how many users are lonely users?
The first line contains a single positive integer , the number of test cases.
lines follow, each line containing a single positive integer , the number of users presently on the platform.
Output lines. On the th line, output the number of lonely users for the th test case.
3 1 10 100
0 9 99