{"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\n\u003cscript\u003e\n window.katexOptions \u003d {\n disable: true\n };\n\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\n","sections":[{"title":"","value":{"format":"HTML","content":"你最喜欢的商店卖N个更美味的惊喜巧克力蛋。你现在知道,S张贴纸和T个玩具总共放在N个巧克力蛋里。\u003cp\u003e\n每一个巧克力蛋的赠品可以是三种类型之一:\u003cp\u003e\n它可以包含一个贴纸,没有玩具;\u003cp\u003e\n它可以包含一个玩具,没有贴纸;\u003cp\u003e\n它可以包含一个贴纸和一个玩具。\u003cp\u003e\n但你不知道哪个的巧克力蛋里包含着什么。所有的巧克力看起来都是一样的,彼此无法区分。你必须购买多少个巧克力才能确保你至少得到一张贴纸和至少一个玩具?\u003cp\u003e\n保证答案总是存在的。\n"}},{"title":"Input","value":{"format":"HTML","content":"第一行包含单个整数t(1≤t≤100)-查询数。\u003cp\u003e\n\n接下来的t行包含三个整数n、s和t(1≤n≤1e9、1≤s、t≤n、s+t\u003d\u003en)-巧克力、贴纸和玩具的数量。\u003cp\u003e\n所有查询都是独立的。\n"}},{"title":"Output","value":{"format":"HTML","content":"打印t整数(每个查询一个数字)-你必须购买的最小数量的巧克力蛋,使得你获得至少一个贴张和一个玩具"}},{"title":"Example","value":{"format":"HTML","content":"\u003cdiv class\u003d\"sample-test\"\u003e\n \u003cdiv class\u003d\"input\"\u003e\n \u003cdiv class\u003d\"title\"\u003e\n Input\n \u003c/div\u003e\n \u003cpre\u003e3\n10 5 7\n10 10 10\n2 1 1\n\u003c/pre\u003e\n \u003c/div\u003e\n \u003cdiv class\u003d\"output\"\u003e\n \u003cdiv class\u003d\"title\"\u003e\n Output\n \u003c/div\u003e\n \u003cpre\u003e6\n1\n2\n\u003c/pre\u003e\n \u003c/div\u003e\n\u003c/div\u003e"}},{"title":"Note","value":{"format":"HTML","content":"\u003cp\u003eIn the first query, we have to take at least $$$6$$$ eggs because there are $$$5$$$ eggs with \u003cspan class\u003d\"tex-font-style-it\"\u003eonly toy\u003c/span\u003e inside and, in the worst case, we\u0027ll buy all of them.\u003c/p\u003e\n\u003cp\u003eIn the second query, all eggs have both a sticker and a toy inside, that\u0027s why it\u0027s enough to buy only one egg.\u003c/p\u003e\n\u003cp\u003eIn the third query, we have to buy both eggs: one with a sticker and one with a toy.\u003c/p\u003e"}}]}