I used a vector of strings to solve this problem — https://mirror.codeforces.com/problemset/problem/4/C
I got a TLE on this, afterwards I saw some other people used map instead of a vector. Could someone kindly inspect my code and explain where I went wrong and tell me why using map is better. My code — https://mirror.codeforces.com/contest/4/submission/85707717