{"raw_statement":[{"iden":"statement","content":"Charles's program works as follows. It first scans the whole colony, building the list of tags of the ants that are recognized. Then it assigns fresh tags to the new ants. To do so, the program simply picks the first natural number (i.e., nonnegative integer) that is not currently assigned to any ant, and so on.\n\nDue to some glitches in the image recognition device and in the program, there are sometimes negative or very large numbers that appear in the input list. These are simply ignored by Charles's program.\n\nYour job is to reimplement the part of Charles's program that finds a fresh tag to assign to a new ant.\n\nThe input consists of the following lines: \n\nThe input satisfies $0 <= N <= 10^6$ . Each integer $X_i$ has less than 100 digits.\n\nThe smallest natural number that does not belong to the set ${X_1, \\\\dots, X_N}$.\n\n"},{"iden":"input","content":"The input consists of the following lines:   on the first line: an integer $N$;  on the next $N$ lines: some integers $X_1, \\\\dots, X_N$ , one per line.  *Limits*The input satisfies $0 <= N <= 10^6$ . Each integer $X_i$ has less than 100 digits."},{"iden":"output","content":"The smallest natural number that does not belong to the set ${X_1, \\\\dots, X_N}$."}],"translated_statement":null,"sample_group":[],"show_order":[],"formal_statement":"**Definitions**  \nLet $ t \\in \\mathbb{Z} $ be the number of test cases.  \nFor each test case $ k \\in \\{1, \\dots, t\\} $:  \n- $ n_k \\in \\mathbb{Z} $ is the length of the string.  \n- $ s_k \\in \\{ \\text{TJ}, \\text{si}, \\text{log} \\}^* $ is a string composed of concatenated substrings \"TJ\", \"si\", and \"log\".  \n\n**Constraints**  \n1. $ 1 \\le t \\le 10^5 $  \n2. $ 1 \\le n_k \\le 10^5 $ for each $ k $  \n3. $ \\sum_{k=1}^{t} n_k < 10^5 $  \n4. $ s_k $ is a valid concatenation of the tokens \"TJ\", \"si\", and \"log\" in some order.  \n\n**Objective**  \nFor each test case $ k $, determine:  \n- $ h_k $: number of occurrences of \"TJ\" (hotdog servings),  \n- $ r_k $: number of occurrences of \"si\" (fried rice servings),  \n- $ e_k $: number of occurrences of \"log\" (egg servings).  \n\nOutput $ (h_k, r_k, e_k) $ for each $ k $.","simple_statement":"Given a string made of parts \"TJ\", \"si\", and \"log\", count how many times each appears. Output: hotdog servings (TJ), fried rice servings (si), egg servings (log).","has_page_source":false}