Problem Description

Build a Playlist object and process commands: ADD song, REMOVE song, COUNT. Songs are unique by name. COUNT prints how many songs are in the playlist.

Input Format

First line q. Next q lines commands.

Output Format

Outputs for COUNT.

Sample Test Case

Input:
8 COUNT ADD song1 ADD song2 COUNT ADD song1 REMOVE song2 COUNT REMOVE song3
Output:
0 2 1

Constraints

q

Solutions (0)

No solutions submitted yet. Be the first!

Discussion (0)

No comments yet. Start the discussion!

Prev Next