{"problem":{"name":"First Query Problem","description":{"content":"You are given an integer $N$ and a sequence $A=(A _ 1,A _ 2,\\ldots,A _ N)$ of length $N$. Given $Q$ queries, process them in the given order. Each query is of one of the following two kinds: *   `1 k","description_type":"Markdown"},"platform":"AtCoder","limit":{"time_limit":2000,"memory_limit":262144},"difficulty":"None","is_remote":true,"is_sync":true,"sync_url":null,"sign":"abc283_b"},"statements":[{"statement_type":"Markdown","content":"You are given an integer $N$ and a sequence $A=(A _ 1,A _ 2,\\ldots,A _ N)$ of length $N$.\nGiven $Q$ queries, process them in the given order. Each query is of one of the following two kinds:\n\n*   `1 k x` : set the value $A _ k$ to $x$.\n*   `2 k` : print the value $A _ k$.\n\n## Constraints\n\n*   $1 \\leq N \\leq 10 ^ 5$\n*   $1 \\leq Q \\leq 10 ^ 5$\n*   $0 \\leq A _ i \\leq 10 ^ 9\\ (1\\leq i\\leq N)$\n*   $1\\leq k\\leq N$ for all queries.\n*   $0\\leq x\\leq 10 ^ 9$ for all queries of the first kind.\n*   There is at least one query of the second kind.\n*   All values in the input are integers.\n\n## Input\n\nThe input is given from Standard Input in the following format:\n\n$N$\n$A _ 1$ $A _ 2$ $\\ldots$ $A _ N$\n$Q$\n$\\operatorname{query} _ 1$\n$\\operatorname{query} _ 2$\n$\\vdots$\n$\\operatorname{query} _ Q$\n\nHere, $\\operatorname{query} _ i$ denotes the $i$\\-th query, given in one of the following formats:\n\n$1$ $k$ $x$\n\n$2$ $k$\n\n[samples]","is_translate":false,"language":"English"}],"meta":{"iden":"abc283_b","tags":[],"sample_group":[["3\n1 3 5\n7\n2 2\n2 3\n1 3 0\n2 3\n1 2 8\n2 2\n2 1","3\n5\n0\n8\n1\n\nInitially, $A=(1,3,5)$.\n\n*   For the $1$\\-st query, $A=(1,3,5)$, where $A _ 2=3$, so $3$ should be printed.\n*   For the $2$\\-nd query, $A=(1,3,5)$, where $A _ 3=5$, so $5$ should be printed.\n*   The $3$\\-rd query sets the value $A _ 3$ to $0$, making $A=(1,3,0)$.\n*   For the $4$\\-th query, $A=(1,3,0)$, where $A _ 3=0$, so $0$ should be printed.\n*   The $5$\\-th query sets the value $A _ 2$ to $8$, making $A=(1,8,0)$.\n*   For the $6$\\-th query, $A=(1,8,0)$, where $A _ 2=8$, so $8$ should be printed.\n*   For the $7$\\-th query, $A=(1,8,0)$, where $A _ 1=1$, so $1$ should be printed."],["5\n22 2 16 7 30\n10\n1 4 0\n1 5 0\n2 2\n2 3\n2 4\n2 5\n1 4 100\n1 5 100\n2 3\n2 4","2\n16\n0\n0\n16\n100"],["7\n478 369 466 343 541 42 165\n20\n2 1\n1 7 729\n1 6 61\n1 6 838\n1 3 319\n1 4 317\n2 4\n1 1 673\n1 3 176\n1 5 250\n1 1 468\n2 6\n1 7 478\n1 5 595\n2 6\n1 6 599\n1 6 505\n2 3\n2 5\n2 1","478\n317\n838\n838\n176\n595\n468"]],"created_at":"2026-03-03 11:01:13"}}