{"id":4913,"date":"2019-03-27T20:31:25","date_gmt":"2019-03-27T17:31:25","guid":{"rendered":"http:\/\/java.mazurok.com\/?p=4913"},"modified":"2019-04-11T00:42:20","modified_gmt":"2019-04-10T21:42:20","slug":"e-olymp-920-%d0%b8%d1%81%d0%bf%d0%be%d0%bb%d1%8c%d0%b7%d0%be%d0%b2%d0%b0%d0%bd%d0%b8%d0%b5-%d1%84%d1%83%d0%bd%d0%ba%d1%86%d0%b8%d0%b9-min-%d0%b8-max","status":"publish","type":"post","link":"https:\/\/java.mazurok.com\/?p=4913","title":{"rendered":"e-olymp 920. \u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 \u0444\u0443\u043d\u043a\u0446\u0438\u0439 min \u0438 max"},"content":{"rendered":"<h1>\u0417\u0430\u0434\u0430\u0447\u0430<\/h1>\n<p>\u0417\u0430\u0434\u0430\u043d\u043e \u0442\u0440\u0438 \u0432\u0435\u0449\u0435\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0445 \u0447\u0438\u0441\u043b\u0430 [latex]x, y[\/latex] \u0438 [latex]z[\/latex]. \u041e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u0442\u044c [latex]\\min\\left(\\max\\left(x,y\\right), \\max\\left(y,z\\right), x+y+z\\right)[\/latex], \u0432\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0432\u0448\u0438\u0441\u044c \u0432\u0441\u043f\u043e\u043c\u043e\u0433\u0430\u0442\u0435\u043b\u044c\u043d\u044b\u043c\u0438 \u0444\u0443\u043d\u043a\u0446\u0438\u044f\u043c\u0438 \u0434\u043b\u044f \u0432\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u044f \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u043e\u0433\u043e \u0438 \u043c\u0430\u043a\u0441\u0438\u043c\u0430\u043b\u044c\u043d\u043e\u0433\u043e \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u043e\u0432 \u0438\u0437 \u0434\u0432\u0443\u0445 \u0437\u0430\u0434\u0430\u043d\u043d\u044b\u0445.<\/p>\n<h1>\u0412\u0445\u043e\u0434\u043d\u044b\u0435 \u0434\u0430\u043d\u043d\u044b\u0435<\/h1>\n<p>\u0412 \u043e\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0435 \u0437\u0430\u0434\u0430\u043d\u043e \u0442\u0440\u0438 \u0432\u0435\u0449\u0435\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0445 \u0447\u0438\u0441\u043b\u0430\u00a0[latex]x, y[\/latex]\u00a0\u0438 [latex]z[\/latex]. \u0417\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u0447\u0438\u0441\u0435\u043b \u043d\u0435 \u043f\u0440\u0435\u0432\u044b\u0448\u0430\u044e\u0442 \u043f\u043e \u043c\u043e\u0434\u0443\u043b\u044e\u00a0[latex]100[\/latex].<\/p>\n<h1>\u0412\u044b\u0445\u043e\u0434\u043d\u044b\u0435 \u0434\u0430\u043d\u043d\u044b\u0435<\/h1>\n<p>\u0412\u044b\u0432\u0435\u0441\u0442\u0438 \u043e\u0442\u0432\u0435\u0442 \u0441 \u0434\u0432\u0443\u043c\u044f \u0434\u0435\u0441\u044f\u0442\u0438\u0447\u043d\u044b\u043c\u0438 \u0437\u043d\u0430\u043a\u0430\u043c\u0438.<\/p>\n<h1>\u0422\u0435\u0441\u0442\u044b<\/h1>\n<table>\n<tbody>\n<tr>\n<th>#<\/th>\n<th>\u0412\u0445\u043e\u0434\u043d\u044b\u0435 \u0434\u0430\u043d\u043d\u044b\u0435<\/th>\n<th>\u0412\u044b\u0445\u043e\u0434\u043d\u044b\u0435 \u0434\u0430\u043d\u043d\u044b\u0435<\/th>\n<\/tr>\n<tr>\n<td>1<\/td>\n<td>\u00a05 6 7<\/td>\n<td>\u00a07.00<\/td>\n<\/tr>\n<tr>\n<td>2<\/td>\n<td>\u00a01.05 2.25 -2.15<\/td>\n<td>\u00a01.15<\/td>\n<\/tr>\n<tr>\n<td>3<\/td>\n<td>\u00a03 3 3<\/td>\n<td>\u00a03<\/td>\n<\/tr>\n<tr>\n<td>4<\/td>\n<td>\u00a08.85 5.67 7.33<\/td>\n<td>\u00a07.33<\/td>\n<\/tr>\n<tr>\n<td>5<\/td>\n<td>\u00a012 -15 13<\/td>\n<td>\u00a010<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<pre class=\"lang:java decode:true \">import java.util.*;\r\nimport java.lang.*;\r\nimport java.io.*;\r\n\r\nclass Ideone\r\n{\r\n\tpublic static void main (String[] args) throws java.lang.Exception\r\n\t{\r\n\t\tdouble x, y, z, min2, max2, max3, n;\r\n\t\tScanner in = new Scanner (System.in);\r\n\t\tx = in.nextDouble();\r\n\t\ty = in.nextDouble();\r\n\t\tz = in.nextDouble();\r\n\t\tmax2 = Math.max(x,y); \/\/\u043d\u0430\u0445\u043e\u0436\u0434\u0435\u043d\u0438\u0435 \u043c\u0430\u043a\u0441\u0438\u043c\u0443\u043c\u0430 \u0438\u0437 x \u0438 y\r\n\t\tmax3 = Math.max(y,z); \/\/\u043d\u0430\u0445\u043e\u0436\u0434\u0435\u043d\u0438\u0435 \u043c\u0430\u043a\u0441\u0438\u043c\u0443\u043c\u0430 \u0438\u0437 y \u0438 z\r\n\t\tmin2 = Math.min(max2,max3); \/\/\u043f\u043e\u0438\u0441\u043a \u043c\u0438\u043d\u0438\u043c\u0443\u043c\u0430 \u0438\u0437 \u043d\u0430\u0439\u0434\u0435\u043d\u043d\u044b\u0445 \u043c\u0430\u043a\u0441\u0438\u043c\u0443\u043c\u043e\u0432 \r\n\t\tn = x + y + z; \/\/\u0441\u0443\u043c\u043c\u0430 3 \u0437\u0430\u0434\u0430\u043d\u043d\u044b\u0445 \u0447\u0438\u0441\u0435\u043b\r\n\t\tmin2 = Math.min(min2,n); \/\/\u043d\u0430\u0445\u043e\u0436\u0434\u0435\u043d\u0438\u0435 \u0434\u0430\u043d\u043d\u043e\u0433\u043e \u043c\u0438\u043d\u0438\u043c\u0443\u043c\u0430\r\n\t\tSystem.out.printf(\"%.2f\",min2);\r\n\t}\r\n}<\/pre>\n<h1>\u0410\u043b\u0433\u043e\u0440\u0438\u0442\u043c \u0440\u0435\u0448\u0435\u043d\u0438\u044f<\/h1>\n<ol>\n<li>\u041d\u0430\u0445\u043e\u0434\u0438\u043c \u043c\u0430\u043a\u0441\u0438\u043c\u0443\u043c \u0438\u0437 [latex]x[\/latex] \u0438 [latex]y[\/latex].<\/li>\n<li>\u041d\u0430\u0445\u043e\u0434\u0438\u043c \u043c\u0430\u043a\u0441\u0438\u043c\u0443\u043c \u0438\u0437 [latex]y[\/latex] \u0438 [latex]z[\/latex].<\/li>\n<li>\u041d\u0430\u0445\u043e\u0434\u0438\u043c \u043c\u0438\u043d\u0438\u043c\u0443\u043c \u0438\u0437 \u043d\u0430\u0439\u0434\u0435\u043d\u043d\u044b\u0445 \u043c\u0430\u043a\u0441\u0438\u043c\u0443\u043c\u043e\u0432.<\/li>\n<li>\u041d\u0430\u0445\u043e\u0434\u0438\u043c \u043c\u0438\u043d\u0438\u043c\u0443\u043c \u0438\u0437 \u043d\u0430\u0439\u0434\u0435\u043d\u043d\u043e\u0433\u043e \u043c\u0438\u043d\u0438\u043c\u0443\u043c\u0430 \u0438 \u0441\u0443\u043c\u043c\u044b \u0434\u0430\u043d\u043d\u044b\u0445 \u0447\u0438\u0441\u0435\u043b.<\/li>\n<\/ol>\n<p>\u0423\u0441\u043b\u043e\u0432\u0438\u0435 \u0437\u0430\u0434\u0430\u0447\u0438 \u043c\u043e\u0436\u043d\u043e \u043d\u0430\u0439\u0442\u0438 \u043d\u0430 <a href=\"https:\/\/www.e-olymp.com\/ru\/problems\/920\" target=\"_blank\" rel=\"noopener noreferrer\">e-olymp<\/a><br \/>\n\u041a\u043e\u0434 \u0440\u0435\u0448\u0435\u043d\u0438\u044f &#8212; <a href=\"https:\/\/ideone.com\/yUEa81\" target=\"_blank\" rel=\"noopener noreferrer\">ideone<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u0417\u0430\u0434\u0430\u0447\u0430 \u0417\u0430\u0434\u0430\u043d\u043e \u0442\u0440\u0438 \u0432\u0435\u0449\u0435\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0445 \u0447\u0438\u0441\u043b\u0430 [latex]x, y[\/latex] \u0438 [latex]z[\/latex]. \u041e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u0442\u044c [latex]\\min\\left(\\max\\left(x,y\\right), \\max\\left(y,z\\right), x+y+z\\right)[\/latex], \u0432\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0432\u0448\u0438\u0441\u044c \u0432\u0441\u043f\u043e\u043c\u043e\u0433\u0430\u0442\u0435\u043b\u044c\u043d\u044b\u043c\u0438 \u0444\u0443\u043d\u043a\u0446\u0438\u044f\u043c\u0438 \u0434\u043b\u044f \u0432\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u044f \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u043e\u0433\u043e \u0438 \u043c\u0430\u043a\u0441\u0438\u043c\u0430\u043b\u044c\u043d\u043e\u0433\u043e \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u043e\u0432 \u0438\u0437 \u0434\u0432\u0443\u0445 \u0437\u0430\u0434\u0430\u043d\u043d\u044b\u0445. \u0412\u0445\u043e\u0434\u043d\u044b\u0435 \u0434\u0430\u043d\u043d\u044b\u0435 \u0412 \u043e\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0435 \u0437\u0430\u0434\u0430\u043d\u043e \u0442\u0440\u0438 \u0432\u0435\u0449\u0435\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0445 \u0447\u0438\u0441\u043b\u0430\u00a0[latex]x, y[\/latex]\u00a0\u0438 [latex]z[\/latex]. \u0417\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u0447\u0438\u0441\u0435\u043b \u043d\u0435 \u043f\u0440\u0435\u0432\u044b\u0448\u0430\u044e\u0442 \u043f\u043e \u043c\u043e\u0434\u0443\u043b\u044e\u00a0[latex]100[\/latex]. \u0412\u044b\u0445\u043e\u0434\u043d\u044b\u0435 \u0434\u0430\u043d\u043d\u044b\u0435 \u0412\u044b\u0432\u0435\u0441\u0442\u0438 \u043e\u0442\u0432\u0435\u0442 \u0441 \u0434\u0432\u0443\u043c\u044f \u0434\u0435\u0441\u044f\u0442\u0438\u0447\u043d\u044b\u043c\u0438 \u0437\u043d\u0430\u043a\u0430\u043c\u0438. \u0422\u0435\u0441\u0442\u044b # \u0412\u0445\u043e\u0434\u043d\u044b\u0435 \u0434\u0430\u043d\u043d\u044b\u0435 \u0412\u044b\u0445\u043e\u0434\u043d\u044b\u0435 &hellip; <a href=\"https:\/\/java.mazurok.com\/?p=4913\" class=\"more-link\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":113,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[2],"tags":[335,355],"jetpack_featured_media_url":"","_links":{"self":[{"href":"https:\/\/java.mazurok.com\/index.php?rest_route=\/wp\/v2\/posts\/4913"}],"collection":[{"href":"https:\/\/java.mazurok.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/java.mazurok.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/java.mazurok.com\/index.php?rest_route=\/wp\/v2\/users\/113"}],"replies":[{"embeddable":true,"href":"https:\/\/java.mazurok.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=4913"}],"version-history":[{"count":2,"href":"https:\/\/java.mazurok.com\/index.php?rest_route=\/wp\/v2\/posts\/4913\/revisions"}],"predecessor-version":[{"id":4915,"href":"https:\/\/java.mazurok.com\/index.php?rest_route=\/wp\/v2\/posts\/4913\/revisions\/4915"}],"wp:attachment":[{"href":"https:\/\/java.mazurok.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=4913"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/java.mazurok.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=4913"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/java.mazurok.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=4913"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}