{"trustable":false,"prependHtml":"\u003cstyle type\u003d\u0027text/css\u0027\u003e\n .input, .output {\n border: 1px solid #888888;\n }\n .output {\n margin-bottom: 1em;\n position: relative;\n top: -1px;\n }\n .output pre, .input pre {\n background-color: #EFEFEF;\n line-height: 1.25em;\n margin: 0;\n padding: 0.25em;\n }\n \u003c/style\u003e\n \u003clink rel\u003d\"stylesheet\" href\u003d\"//codeforces.org/s/96598/css/problem-statement.css\" type\u003d\"text/css\" /\u003e\u003cscript\u003e window.katexOptions \u003d { disable: true }; \u003c/script\u003e\n\u003cscript type\u003d\"text/x-mathjax-config\"\u003e\n MathJax.Hub.Config({\n tex2jax: {\n inlineMath: [[\u0027$$$\u0027,\u0027$$$\u0027], [\u0027$\u0027,\u0027$\u0027]],\n displayMath: [[\u0027$$$$$$\u0027,\u0027$$$$$$\u0027], [\u0027$$\u0027,\u0027$$\u0027]]\n }\n });\n\u003c/script\u003e\n\u003cscript type\u003d\"text/javascript\" async src\u003d\"https://mathjax.codeforces.org/MathJax.js?config\u003dTeX-AMS_HTML-full\"\u003e\u003c/script\u003e","sections":[{"title":"题目描述","value":{"format":"MD","content":"TXT 决定在高考结束后想办法赚点外快,于是做了剧本杀的 DM 。\n\n但是 TXT 发现存在同名顾客,会导致账本混乱,所以 TXT 想请你写一个程序帮助他区分不同的顾客。\n\n这一天,TXT 共接待了 $$$n$$$ 名顾客,如果顾客的名字以前没有出现过就返回 \"OK\" ,表示可以直接将顾客的名字记录到账本上,否则在顾客的名字后面添加一个数字并返回,以区分不同的顾客。例如如果存在 $$$3$$$ 名名为 fgh 的顾客,则第二个顾客记为 fgh1 ,第三名顾客记为 fgh2 。"}},{"title":"输入格式","value":{"format":"MD","content":"第一行包含一个 $$$n$$$ ($$$1 \\le n \\le 10^5$$$) 表示顾客的数量。\n\n接下来的 $$$n$$$ 行每行包含一个长度小于 $$$32$$$ 的非空字符串,表示顾客的名字。"}},{"title":"输出格式","value":{"format":"MD","content":"打印 $$$n$$$ 行,每一行表示程序的返回结果。"}},{"title":"样例 #1","value":{"format":"MD","content":"\u003ctable class\u003d\u0027vjudge_sample\u0027\u003e\n\u003cthead\u003e\n \u003ctr\u003e\n \u003cth\u003eInput\u003c/th\u003e\n \u003cth\u003eOutput\u003c/th\u003e\n \u003c/tr\u003e\n\u003c/thead\u003e\n\u003ctbody\u003e\n \u003ctr\u003e\n \u003ctd\u003e\u003cpre\u003e5\nfgh\nelegy\nfgh\ntrubiacy\nfgh\n\u003c/pre\u003e\u003c/td\u003e\n \u003ctd\u003e\u003cpre\u003eOK\nOK\nfgh1\nOK\nfgh2\n\u003c/pre\u003e\u003c/td\u003e\n \u003c/tr\u003e\n\u003c/tbody\u003e\n\u003c/table\u003e\n"}}]}