{"width":"100%","blog_title":"\u30d7\u30ed\u30b0\u30e9\u30e0\u30e2\u30b0\u30e2\u30b0","image_url":"https://blog.st-hatena.com/images/theme/og-image-1500.png","provider_url":"https://hatena.blog","blog_url":"https://itchyny.hatenablog.com/","provider_name":"Hatena Blog","url":"https://itchyny.hatenablog.com/entry/2016/06/18/230000","height":"190","type":"rich","html":"<iframe src=\"https://hatenablog-parts.com/embed?url=https%3A%2F%2Fitchyny.hatenablog.com%2Fentry%2F2016%2F06%2F18%2F230000\" title=\"AtCoder Beginner Contest 040 - \u30d7\u30ed\u30b0\u30e9\u30e0\u30e2\u30b0\u30e2\u30b0\" class=\"embed-card embed-blogcard\" scrolling=\"no\" frameborder=\"0\" style=\"display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;\"></iframe>","author_url":"https://blog.hatena.ne.jp/itchyny/","categories":["atcoder"],"author_name":"itchyny","description":"A - \u8d64\u8d64\u8d64\u8d64\u9752 n\u500b\u306e\u4e2d\u306e\u7279\u5b9a\u306e\u4e00\u3064\u306e\u30d6\u30ed\u30c3\u30af\u3092\u96a3\u308a\u5408\u3046\u30d6\u30ed\u30c3\u30af\u306e\u5165\u308c\u66ff\u3048\u306b\u3088\u3063\u3066\u4e21\u7aef\u306e\u3044\u305a\u308c\u304b\u306b\u79fb\u52d5\u3059\u308b\u6700\u5c0f\u306e\u56de\u6570\u3002 main :: IO () main = getContents >>= print . (\\[n, x] -> min (x - 1) (n - x)) . map read . words B - \u25a1\u25a1\u25a1\u25a1\u25a1 n\u500b\u306e\u30bf\u30a4\u30eb\u3092\u3069\u308c\u3060\u3051\u305f\u304f\u3055\u3093\u4f7f\u3063\u3066\u3067\u304d\u308b\u9650\u308a\u6b63\u65b9\u5f62\u306b\u4e26\u3079\u3089\u308c\u308b\u304b\u3002\u6307\u6a19\u306f\u4e8c\u8fba\u306e\u5dee\u3068\u4f7f\u3044\u5207\u308c\u306a\u304b\u3063\u305f\u30bf\u30a4\u30eb\u306e\u6570\u306e\u548c\u304c\u6700\u5c0f\u306e\u3082\u306e\u3002 main :: IO () main = readLn >>= print . solve solve :: Int -> Int \u2026","published":"2016-06-18 23:00:00","version":"1.0","title":"AtCoder Beginner Contest 040"}