Problem Description

You have q commands: INC key, DEC key. Start counts at 0. If after DEC the count becomes 0, remove the key from dictionary. At end output number of keys left.

Input Format

First line q. Next q lines commands.

Output Format

One integer keysLeft.

Constraints

1

Solutions (0)

No solutions submitted yet. Be the first!

Discussion (0)

No comments yet. Start the discussion!

Prev Next