After entering Seondeok High School, Dadas wants to make new friends in the classroom during breaks.
The classroom is initially empty, but as time passes, many students enter and leave. Dadas is lazy, so instead of going outside the classroom, Dadas wants to become friends with students who enter the classroom by playing with them. Since Dadas is very sociable, whenever Dadas plays, every student currently in the classroom instantly becomes Dadas's friend.
There are students other than Dadas, numbered from to . Initially, none of them is Dadas's friend.
Process the following queries.
1 i: Student enters the classroom.2 i: Student leaves the classroom.3: Dadas plays with the students in the classroom. Every student currently in the classroom becomes Dadas's friend.4: Print the current number of Dadas's friends.
All queries are consistent with the actual classroom state. That is, a student who is already in the classroom will not enter again, and a student who is outside the classroom will not leave.
Input
The input is given in the following format.
Each represents one query and is one of the following forms: 1 i, 2 i, 3, or 4.
Output
For each query of type 4, print the current number of Dadas's friends on its own line.
Constraints
- .
- .
- In queries of the form
1 ior2 i, . - All queries are consistent with the actual classroom state.
Subtasks
Samples
At the first query of type 4, Dadas has no friends yet.
After playing, students and , who were in the classroom, become Dadas's friends.
Later, student enters the classroom and Dadas plays again, so the number of friends becomes .
During the first play query, the classroom is empty, so no new student becomes a friend.
Later, student is in the classroom when Dadas plays, so student becomes Dadas's friend.
해설
관리자가 작성한 해설을 별도 페이지에서 볼 수 있어요.