{"id":9776,"date":"2011-07-16T16:02:00","date_gmt":"2011-07-16T16:02:00","guid":{"rendered":"http:\/\/melotopia.net\/b\/?p=9776"},"modified":"2011-07-16T16:02:00","modified_gmt":"2011-07-16T16:02:00","slug":"%ea%b0%80%ea%b2%8c-%ec%97%ac%eb%8a%94-%ec%8b%9c%ea%b0%84","status":"publish","type":"post","link":"http:\/\/melotopia.net\/b\/?p=9776","title":{"rendered":"\uac00\uac8c \uc5ec\ub294 \uc2dc\uac04"},"content":{"rendered":"<div class=\"desc\">\n<a href=\"http:\/\/kldp.org\/node\/124415\" target=\"_blank\" title=\"[http:\/\/kldp.org\/node\/124415]\ub85c \uc774\ub3d9\ud569\ub2c8\ub2e4.\"><br \/>\n         http:\/\/kldp.org\/node\/124415<br \/>\n        <\/a><\/p>\n<p>        \uc704\uc758 \ubb38\uc81c\ub97c \ud480\uc5b4\ubcf4\uc558\ub2e4.<\/p>\n<p>        \ubb38\uc81c: \uc5b4\ub5a4 \uac00\uac8c\uac00 \uc5ec\ub294 \uc2dc\uac04\uc774 a, \ub2eb\ub294 \uc2dc\uac04\uc774 b\ub77c\uace0 \ud558\uc790. x\ub97c \uc785\ub825\ud558\uba74 \uac00\uac8c\uac00 \uc5f4\uc5c8\ub294\uc9c0 \ub2eb\uc558\ub294\uc9c0 \uc54c\ub824\uc8fc\ub294 \ud568\uc218\ub97c \ub9cc\ub4e4\uc5b4 \ubcf4\uc790.<br \/>\n        <br \/>\n        \uc608: a=2\uc2dc, b=15\uc2dc. f(x=12)=true, f(x=1)=false, f(x=17)=false<br \/>\n        <br \/>\n        \uc608: a=20\uc2dc, b=5\uc2dc. f(x=1)=true, f(x=12)=false, f(x=23)=true<\/p>\n<p>        C\uc5b8\uc5b4\ub77c\uace0 \uac00\uc815\ud558\uc790.<br \/>\n        <br \/>\n        \uac00\uc7a5 \ube60\ub974\uac8c \ub5a0\uc624\ub974\ub294 \ub2f5\uc740 \ub2e4\uc74c\uacfc \uac19\ub2e4.<br \/>\n        <\/p>\n<div class=\"txc-textbox\" style=\"border-style: solid; border-width: 1px; border-color: rgb(254, 254, 184); background-color: rgb(254, 254, 184); padding: 10px;\">\n         isOpen(int a, int b, int x){<br \/>\n         <br \/>\n         if a<b {\n         <br \/>\n         if a<x &#038;&#038; x<b{\n         <br \/>\n         return true;<br \/>\n         <br \/>\n         } else{<br \/>\n         <br \/>\n         return false;<br \/>\n         <br \/>\n         }<br \/>\n         <br \/>\n         } else {<br \/>\n         <br \/>\n         if a>x || x>b{<br \/>\n         <br \/>\n         return true;<br \/>\n         <br \/>\n         } else{<br \/>\n         <br \/>\n         return false;<br \/>\n         <br \/>\n         }<br \/>\n         <br \/>\n         }<br \/>\n         <br \/>\n         }<br \/>\n         \n<\/div>\n<p>\n        KLDP\uac8c\uc2dc\ud310\uc5d0 \ub9ce\uc740 \uace0\uc218\ubd84\ub4e4\uc774 \uad1c\ucc2e\uc740 \ud480\uc774\ub97c \uc62c\ub838\ub294\ub370, \uadf8\uc911\uc5d0 \ub0b4\uac00 \uc81c\uc548\ud55c \uac83 \ub450\uac00\uc9c0\ub9cc \uc5ec\uae30\uc11c \uc124\uba85\ud558\ub3c4\ub85d \ud558\uaca0\ub2e4.<\/p>\n<p>        \uccab\ubc88\uc9f8\ub85c<br \/>\n        <\/p>\n<pre class=\"text geshifilter-text\" style=\"font-family:monospace;\"><div class=\"txc-textbox\" style=\"border-style: solid; border-width: 1px; border-color: rgb(231, 253, 181); background-color: rgb(231, 253, 181); padding: 10px;\">\r\nisOpen(int a, int b, int x){\r\n    return ((a-b)(x-a)(x-b)\/abs((a-b)(x-a)(x-b))+1)\/2;\r\n}<span style=\"font-family: sans-serif;\"><br\/>\r\n<\/span><\/div>\r\n<\/pre>\n<p>        \uc77c\ub2e8 a<b\uc778 \uacbd\uc6b0\uc5d0 a<x<b\uc774\uba74 \ucc38\uc744 \ubc18\ud658\ud558\uace0, a>b\uc778 \uacbd\uc6b0\uc5d0 b<x<a\uc774\uba74 \uac70\uc9d3\uc744 \ubc18\ud658\ud558\uba74 \ub41c\ub2e4. \uc798 \uc0dd\uac01\ud574\ubcf4\uba74, x-a\uc640 x-b\uac00 a<b\uc778 \uacbd\uc6b0\uc5d0\ub294 \ubd80\ud638\uac00 \ub2ec\ub77c\uc9c4\ub2e4\ub294 \uc0ac\uc2e4\uc744 \uc54c \uc218 \uc788\ub2e4. \uadf8\ub9ac\uace0 a-b<0\uc774\ub2e4. \ub530\ub77c\uc11c (a-b)(x-a)(x-b)\ub294 a<b\uc774\uace0 a<x<b\uc778 \uacbd\uc6b0\uc5d0\ub294 \uc591\uc218\uac00 \ub41c\ub2e4. \ubc18\ub300\ub85c a>b\uc774\uba74 a-b\ub294 \uc591\uc218\uc774\ub2e4. \uc774 \uacbd\uc6b0\uc5d0\ub3c4 b<x<a\uc774\uba74 x-a\uc640 x-b\ub294 \ubd80\ud638\uac00 \ub2e4\ub974\ub2e4. \ub530\ub77c\uc11c \uc138 \ud56d\uc758 \uacf1\uc740 \uc74c\uc218\uac00 \ub41c\ub2e4. \uc774 \ud2b9\uc9d5\uc744 \uc774\uc6a9\ud558\uba74 true\uc778 \uacbd\uc6b0\uc5d0\ub294 \uc591\uc218\uc774\uace0 false\uc778 \uacbd\uc6b0\uc5d0\ub294 \uc74c\uc218\uac00 \ub41c\ub2e4\ub294 \uc0ac\uc2e4\uc744 \uc54c\uc544\ub0bc \uc218 \uc788\ub2e4. false\ub294 0\uc774\ubbc0\ub85c \uc74c\uc218\uc778 \uacbd\uc6b0\uc5d0 0\uc744 \ubc18\ud658\ud574\uc8fc\uae30 \uc704\ud558\uc5ec \uc2dd\uc744 \uc880 \ub354 \ubcf5\uc7a1\ud558\uac8c \uc37c\ub2e4.\n        <br \/>\n        \uc774 \ud568\uc218\uc758 \ubb38\uc81c\ub294 a=b, a=x, b=x\uc778 \uacbd\uc6b0\uc5d0\ub294 0\uc73c\ub85c \ub098\ub204\ub294 \ubb38\uc81c\uac00 \ubc1c\uc0dd\ud55c\ub2e4\ub294 \uc810\uc774\ub2e4. \uc608\uc678\ucc98\ub9ac\ub97c \uc704\ud574\uc11c if\ubb38\uc744 \uc4f8 \uc218\ubc16\uc5d0 \uc5c6\uac8c \ub41c\ub2e4.<\/p>\n<p>        \ub450\ubc88\uc9f8\ub85c<br \/>\n        <\/p>\n<div class=\"txc-textbox\" style=\"border-style: solid; border-width: 1px; border-color: rgb(219, 232, 251); background-color: rgb(219, 232, 251); padding: 10px;\">\n         isOpen(int a, int b, int x){<br \/>\n         <br \/>\n         return (x-a+n)%n<(b-a+n)%n;\n         <br \/>\n         }\n        <\/div>\n<p>\n        \uc5ec\uae30\uc11c n\uc740 \ud558\ub8e8\uc758 \uae38\uc774\ub97c \ub098\ud0c0\ub0b4\ub294 \uc815\uc218\uc774\ub2e4. \uc774\ub7f0\uc2dd\uc73c\ub85c \uacc4\uc0b0\ud558\ub294 \uac83\uc774 \uac00\ub2a5\ud55c \uac83\uc740 24\uc2dc\uac04\uc744 \uae30\uc900\uc73c\ub85c \ud560 \ub54c \ud56d\uc0c1 x<b\uc774\uae30\ub9cc \ud558\uba74 \ub418\uae30 \ub54c\ubb38\uc774\ub2e4. a\uc640 b\uac00 \uc785\ub825\ub418\ub294 \uc22b\uc790\ub85c\ub294 a<b\uc774\uac70\ub098 a>b\uc77c \uc218 \uc788\uaca0\uc9c0\ub9cc(a=b\ub294?) \uc2e4\uc81c \uac1c\ub150\uc73c\ub85c\ub294 \ud56d\uc0c1 a<x<b\uc774 \uc131\ub9bd\ud55c\ub2e4. \ub530\ub77c\uc11c 0<x-a<b-a\ub3c4 \ud56d\uc0c1 \uc131\ub9bd\ud55c\ub2e4. x-a\uc640 b-a\ub294 \ud558\ub8e8\uc758 \uae38\uc774 \ub0b4\uc5d0\uc11c \uc874\uc7ac\ud558\ubbc0\ub85c %\uc5f0\uc0b0\uc790\ub97c \uc368\uc11c \ud558\ub8e8 \ub2e8\uc704\ub85c \uc798\ub77c\uc900\ub2e4. \uadf8\ub7f0\ub370 a>b\uc778 \uacbd\uc6b0\uc5d0\ub294 b-a\uac00 \uc74c\uc218\uac00 \ub418\ub294\ub370, \uadf8\ub7f0 \uc0ac\ud0dc\ub97c \ub9c9\uae30 \uc704\ud574\uc11c \uc591\ubcc0\uc5d0 n\uc744 \ub354\ud574\uc900 \ud6c4\uc5d0 %\ub85c \uc798\ub77c\uc8fc\uac8c \ub41c\ub2e4.<\/p>\n<p>        \uc138\ubc88\uc9f8\ub85c<br \/>\n        <\/p>\n<div class=\"txc-textbox\" style=\"border-style: solid; border-width: 1px; border-color: rgb(238, 238, 238); background-color: rgb(238, 238, 238); padding: 10px;\">\n         isOpen(int a, int b, int x){<br \/>\n         <br \/>\n         return (a-b)(x-a)(x-b)>0;<br \/>\n         <br \/>\n         }\n        <\/div>\n<p>\n        \uccab\ubc88\uc9f8 \ub2f5\uc758 \ubcc0\ud615\uc774\ub2e4. \uc14b \uc911\uc5d0\uc11c \uc81c\uc77c \uac04\ub2e8\ud55c \uac83 \uac19\ub2e4<br \/>\n        <br \/>\n        .<br \/>\n        <\/p>\n<div style=\"width:100%;margin-top:30px;clear:both;height:30px\">\n<div style=\"width:31px;float:left;\">\n<a href=\"\/toolbar\/popup\/abuseReport\/?entryId=2607\" onclick=\"window.open(this.href, 'tistoryThisBlogPopup', 'width=550, height=510, toolbar=no, menubar=no, status=no, scrollbars=no'); return false;\"><br \/>\n<img data-recalc-dims=\"1\" decoding=\"async\" alt=\"\uc2e0\uace0\" src=\"https:\/\/i0.wp.com\/t1.daumcdn.net\/tistory_admin\/static\/ico\/ico_spam_report.png\" style=\"border:0\"\/><br \/>\n<\/a>\n<\/div>\n<\/div>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>http:\/\/kldp.org\/node\/124415 \uc704\uc758 \ubb38\uc81c\ub97c \ud480\uc5b4\ubcf4\uc558\ub2e4. \ubb38\uc81c: \uc5b4\ub5a4 \uac00\uac8c\uac00 \uc5ec\ub294 \uc2dc\uac04\uc774 a, \ub2eb\ub294 \uc2dc\uac04\uc774 b\ub77c\uace0 \ud558\uc790. x\ub97c \uc785\ub825\ud558\uba74 \uac00\uac8c\uac00 \uc5f4\uc5c8\ub294\uc9c0 \ub2eb\uc558\ub294\uc9c0 \uc54c\ub824\uc8fc\ub294 \ud568\uc218\ub97c \ub9cc\ub4e4\uc5b4 \ubcf4\uc790. \uc608: a=2\uc2dc, b=15\uc2dc. f(x=12)=true, f(x=1)=false, f(x=17)=false \uc608: a=20\uc2dc, b=5\uc2dc. f(x=1)=true, f(x=12)=false, f(x=23)=true C\uc5b8\uc5b4\ub77c\uace0 \uac00\uc815\ud558\uc790. \uac00\uc7a5 \ube60\ub974\uac8c \ub5a0\uc624\ub974\ub294 \ub2f5\uc740 \ub2e4\uc74c\uacfc \uac19\ub2e4. isOpen(int a, int b, int x){ if a<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_crdt_document":"","_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[12],"tags":[],"class_list":["post-9776","post","type-post","status-publish","format-standard","hentry","category-12"],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/p8o6gA-2xG","jetpack-related-posts":[],"jetpack_likes_enabled":true,"_links":{"self":[{"href":"http:\/\/melotopia.net\/b\/index.php?rest_route=\/wp\/v2\/posts\/9776","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/melotopia.net\/b\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/melotopia.net\/b\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/melotopia.net\/b\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/melotopia.net\/b\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=9776"}],"version-history":[{"count":0,"href":"http:\/\/melotopia.net\/b\/index.php?rest_route=\/wp\/v2\/posts\/9776\/revisions"}],"wp:attachment":[{"href":"http:\/\/melotopia.net\/b\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=9776"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/melotopia.net\/b\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=9776"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/melotopia.net\/b\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=9776"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}