{"id":1167,"date":"2008-04-25T23:59:00","date_gmt":"2008-04-25T14:59:00","guid":{"rendered":"https:\/\/hdmr.org\/d\/read.php\/1209135567"},"modified":"2008-04-25T23:59:00","modified_gmt":"2008-04-25T14:59:00","slug":"read-1209135567","status":"publish","type":"post","link":"http:\/\/hdmr.org\/d\/read.php\/1209135567","title":{"rendered":"C#\u3092\u4f7f\u3046\u306e\u306f\u697d\u3068\u3044\u3046\u3088\u308a\u30b9\u30de\u30fc\u30c8\u306b\u66f8\u3051\u308b\u304b\u3089?"},"content":{"rendered":"<p>\u56de\u8def\u3067\u76f8\u4e92\u30a4\u30f3\u30c0\u30af\u30bf\u30f3\u30b9\u304c\u51fa\u3066\u304d\u3066\u3044\u308d\u3044\u308d\u3084\u3063\u3066\u305f\u308a\u3059\u308b\u3002<br \/>\u307e\u3041\u3057\u304b\u3057\u3001T\u578b\u7b49\u4fa1\u56de\u8def\u306b\u5909\u63db\u3059\u308b\u3068-M[H]\u306e\u30a4\u30f3\u30c0\u30af\u30bf\u30f3\u30b9\u304c\u51fa\u3066\u304d\u305f\u308a\u3059\u308b\u3051\u3069\u3001<br \/>\u305d\u3093\u306a\u3082\u306e\u306f\u73fe\u5b9f\u306b\u306f\u306a\u3044\u308f\u306a\u3002<br \/>\u8a08\u7b97\u306e\u4e16\u754c\u3067\u306f\u3053\u308c\u304c\u4fbf\u5229\u3067\u3082\u3001\u5b9f\u969b\u306b\u898b\u308c\u306a\u3044\u306e\u306f\u6b8b\u5ff5\u306a\u8a71\u3060\u3002<br \/>\u3055\u3066\u3001C#\u3067\u4f55\u304b\u3068\u30d7\u30ed\u30b0\u30e9\u30e0\u3092\u66f8\u3044\u3066\u3044\u307e\u3059\u3002<br \/>\u6700\u8fd1\u306fC\u30fbPHP\u30fbPerl\u30fbC#\u3068\u3044\u308d\u3044\u308d\u4f7f\u3044\u307e\u3059\u3051\u3069\u3001\u3084\u3063\u3071\u308a\u5f79\u5272\u306f\u9055\u3044\u307e\u3059\u306d\u3002<br \/>Web\u4ee5\u5916\u3067PHP\u306f\u4f7f\u308f\u306a\u3044\u3057\u3001C\u3067\u66f8\u304f\u306e\u306f\u5b9f\u7528\u7684\u3068\u3044\u3046\u3088\u308a\u5b9f\u9a13\u7684\u306a\u3082\u306e\u3070\u3063\u304b\u308a\u3060\u306a\u3002<br \/>\u307e\u3041\u5b9f\u7528\u7684\u306a\u3082\u306e\u306f\u3001Perl\u304bC#\u3068\u3044\u3046\u3053\u3068\u3067\u3059\u3002<br \/>\u3053\u3053\u3067C#\u306f\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u6307\u5411\u3068\u3044\u3046\u306e\u304c\u6839\u5e95\u306b\u3042\u308b\u3093\u3060\u304b\u3089\u3001\u3084\u3063\u3071\u308a\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u3092\u6271\u3044\u3084\u3059\u3044\u306d\u3002<br \/>\u305d\u3093\u306a\u308f\u3051\u3067Class\u306e\u5927\u91cf\u88fd\u9020\u3060\u3002<br \/>\u3055\u3066\u3001\u4eca\u56de\u3084\u3063\u3066\u308b\u306e\u306f\u969c\u5bb3\u7269\u306e\u7f6e\u304b\u308c\u305f\u5ea7\u6a19\u4e0a\u3067\u3001\u4efb\u610f\u306e2\u70b9\u306e\u79fb\u52d5\u65b9\u6cd5\u3092\u8abf\u3079\u308b\u3084\u3064\u3002<br \/>\u305f\u3060\u3057\u79fb\u52d5\u306fX\u8ef8\u65b9\u5411\u304bY\u8ef8\u65b9\u5411\u3060\u3051\u3002<br \/>\u307e\u3041\u3053\u3046\u3044\u3046\u3053\u3068\u3092\u8003\u3048\u308b\u306e\u306b\u7528\u610f\u3057\u305fClass\u306fmap\u3068vector\u3060\u3002<br \/>vector\u3068\u3044\u3046\u306e\u306f\u975e\u5e38\u306b\u91cd\u8981\u3060\u3002<br \/>C#\u306b\u306f\u6a19\u6e96\u3067\u306f\u3053\u306e\u624b\u306eClass\u304c\u306a\u3044\u306e\u306f\u975e\u5e38\u306b\u6b8b\u5ff5\u3002\u3042\u3063\u305f\u3089\u7d99\u627f\u3057\u3066\u4f7f\u3046\u3093\u3060\u3051\u3069\u306a\u3041\u2026<br \/>\u3068\u3044\u3046\u308f\u3051\u3067x\u3068y\u306b\u4f7f\u3046\u5909\u6570\u3092\u7528\u610f\u3057\u3066\u3001\u30d7\u30ed\u30d1\u30c6\u30a3\u30fc\u3092\u4f5c\u3063\u3066\u3001<br \/>+&#44;-&#44;*\u306e\u6f14\u7b97\u5b50\u3092\u5b9a\u7fa9\u3057\u3066\u3001IFormattable\u3092\u5b9f\u88c5\u3057\u3064\u3064ToString\u3092\u4f5c\u3063\u3066\u304a\u3044\u305f\u3002<br \/>\u3082\u3057\u6a19\u6e96\u3067\u3053\u306e\u624b\u306e\u30af\u30e9\u30b9\u304c\u3042\u3063\u305f\u3089\u3053\u3053\u307e\u3067\u306f\u7701\u7565\u3067\u304d\u305f\u306a\u3002<br \/>\u3067\u3001\u4f5c\u696d\u3092\u7c21\u5358\u306b\u3059\u308b\u305f\u3081\u306b\u3053\u3093\u306aStatic\u306a\u30e1\u30bd\u30c3\u30c9\u3092\u4f5c\u3063\u305f\u3002<br \/>(0&#44;5)\u3068\u3044\u3046\u79fb\u52d5\u304c\u3042\u3063\u305f\u3068\u304d\u3001\u3053\u306e\u5148\u306b\u969c\u5bb3\u7269\u304c\u306a\u3044\u304b\u78ba\u304b\u3081\u306a\u3044\u3068\u3044\u3051\u306a\u3044\u3002<br \/>\u305d\u306e\u305f\u3081\u306b\u306f(0&#44;0)\u2026(0.5)\u9032\u3093\u3060\u3068\u3053\u308d\u3092\u78ba\u304b\u3081\u306a\u3044\u3068\u3044\u3051\u306a\u3044\u3002(0&#44;0)\u306f\u3044\u3089\u3093\u6c17\u3082\u3059\u308b\u3051\u3069\u3002<br \/>\u79fb\u52d5\u306e\u30d9\u30af\u30c8\u30eb\u3092\u6e21\u3057\u305f\u3089\u305d\u306e\u9032\u3093\u3067\u78ba\u304b\u3081\u306a\u3044\u3068\u3044\u3051\u306a\u3044\u5148\u3092\u4e26\u3079\u305f\u914d\u5217\u3092\u3082\u3089\u3048\u308b\u3068\u3044\u3046\u3082\u306e\u3002<br \/>\u3053\u3093\u306a\u306efor\u30eb\u30fc\u30d7\u56de\u305b\u3070\u3044\u3044\u3058\u3083\u306a\u3044\u304b\u3068\u8a00\u3046\u304b\u3082\u3057\u308c\u306a\u3044\u3051\u3069\u7d50\u69cb\u306a\u624b\u9593\u3060\u3002<br \/>\u305d\u3053\u3067\u3053\u3053\u304b\u3089\u3082\u3089\u3063\u3066\u3053\u308c\u3070\u3053\u308c\u3060\u3051\u3067\u3044\u3044\u3002<\/p>\n<pre>foreach(vector vc in autoarr(v)){<br \/>  if(!mymap.check(p+vc))  return false;<br \/>}<\/pre>\n<p>\u306a\u3093\u304bPerl\u306eforeach\u306e\u4f7f\u3044\u65b9\u307f\u305f\u3044\u306a\u6c17\u3082\u3059\u308b\u304c\u3001\u3053\u308c\u306f\u3053\u308c\u3067\u3042\u308a\u3067\u3057\u3087\u3046\u3002<br \/>\u5b9f\u969b(2.3)\u306b\u5bfe\u3057\u3066\u3001(0&#44;0)\u2026(0&#44;3)&#44;(1&#44;0)\u2026(2&#44;3)\u3068\u3044\u3046\u306e\u3092\u8fd4\u305b\u308b\u3088\u3046\u306b\u306a\u3063\u3066\u305f\u308a\u3068\u3001<br \/>\u6709\u7528\u306a\u70b9\u306f\u3044\u308d\u3044\u308d\u3042\u308b\u3002<br \/>\u307e\u3041\u3053\u3093\u306a\u9053\u5177\u3092\u7528\u610f\u3057\u3066\u304a\u3044\u3066\u3001map\u306eClass\u306b\u3001\u30eb\u30fc\u30c8\u63a2\u7d22\u306e\u30e1\u30bd\u30c3\u30c9\u3092\u8003\u3048\u306a\u304c\u3089\u4f5c\u3063\u3066\u3044\u308b\u3002<br \/>\u5ea7\u6a19\u3082\u79fb\u52d5\u3082\u4f55\u3082\u304b\u3082vector\u3067\u6df7\u4e71\u3057\u305d\u3046\u306b\u306a\u308b\u306e\u306f\u5384\u4ecb\u3060\u306a\u3002<br \/>\u518d\u5e30\u7684\u306b\u30e1\u30bd\u30c3\u30c9\u3092\u547c\u3073\u51fa\u3059\u3079\u304d\u304b\u3068\u304b\u3044\u308d\u3044\u308d\u8003\u3048\u3066\u308b\u3051\u3069\u306a\u3002<br \/>\u6700\u7d42\u7684\u306b\u306fmap\u306e\u305d\u306e\u30e1\u30bd\u30c3\u30c9\u3092\u52d5\u304b\u3059\u3060\u3051\u3067\u3001\u30eb\u30fc\u30c8\u304cvector[]\u3067\u3082\u3089\u3048\u308b\u3068\u3044\u3046\u306e\u3092\u4e88\u60f3\u3057\u3066\u3044\u308b\u3002<br \/>\u3082\u3057\u304b\u3059\u308b\u3068\u30d5\u30a1\u30a4\u30eb\u8aad\u307f\u8fbc\u307f\u3067map\u3092\u4f5c\u6210\u3059\u308b\u3068\u304d\u306b\u81ea\u52d5\u7684\u306b\u7b97\u51fa\u3057\u3066\u3001\u7d50\u679c\u3092\u4fdd\u5b58\u3057\u3066\u304a\u304f\u3088\u3046\u306b\u3059\u308b\u304b\u3082\u3057\u308c\u3093\u304c\u3002<br \/>\u307e\u3041\u3069\u3061\u3089\u306b\u3057\u3066\u3082map\u306e\u3053\u3068\u3092\u77e5\u3089\u306a\u3044\u4eba\u3067\u3082\u3001\u5c11\u3057\u306e\u64cd\u4f5c\u3067\u30eb\u30fc\u30c8\u3092\u5f97\u308b\u3053\u3068\u304c\u3067\u304d\u308b\u3002<br \/>\u3044\u304f\u3089\u82e6\u52b4\u3057\u3066\u4f5c\u3063\u3066\u3082\u3001\u3053\u308c\u3092\u898b\u306a\u3044\u3067\u4f7f\u3048\u308b\u3068\u8a00\u3046\u3053\u3068\u3067\u3059\u3002\u3044\u3084\u306f\u3084\u3001\u30ab\u30d7\u30bb\u30eb\u5316\u3063\u3066\u6050\u308d\u3057\u3044\u3067\u3059\u306d\u3002<br \/>\u3057\u304b\u3057\u4eca\u3044\u308d\u3044\u308d\u66f8\u3044\u3066\u308b\u304c\u3001\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u306e\u76f8\u4e92\u95a2\u4fc2\u3067\u30d7\u30ed\u30b0\u30e9\u30e0\u3092\u8868\u3057\u3066\u308b\u6c17\u306f\u3057\u306a\u3044\u306a\u3002<br \/>\u3046\u30fc\u3093\u2026\u73fe\u5728\u4f4d\u7f6e\u306eClass\u3067\u3082\u4f5c\u308d\u3046\u304b\u306a\u3041\u2026\u305d\u3046\u3059\u308c\u3070\u30b9\u30de\u30fc\u30c8\u306b\u306a\u308b\u304b?<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u56de\u8def\u3067\u76f8\u4e92\u30a4\u30f3\u30c0\u30af\u30bf\u30f3\u30b9\u304c\u51fa\u3066\u304d\u3066\u3044\u308d\u3044\u308d\u3084\u3063\u3066\u305f\u308a\u3059\u308b\u3002\u307e\u3041\u3057\u304b\u3057\u3001T\u578b\u7b49\u4fa1\u56de\u8def\u306b\u5909\u63db\u3059\u308b\u3068-M[H]\u306e\u30a4\u30f3\u30c0\u30af\u30bf\u30f3\u30b9\u304c\u51fa\u3066\u304d\u305f\u308a\u3059\u308b\u3051\u3069\u3001\u305d\u3093\u306a\u3082\u306e\u306f\u73fe\u5b9f\u306b\u306f\u306a\u3044\u308f\u306a\u3002\u8a08\u7b97\u306e\u4e16\u754c\u3067\u306f\u3053\u308c\u304c\u4fbf\u5229\u3067\u3082\u3001\u5b9f\u969b\u306b\u898b\u308c\u306a\u3044\u306e\u306f [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-1167","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"_links":{"self":[{"href":"http:\/\/hdmr.org\/d\/index.php?rest_route=\/wp\/v2\/posts\/1167","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/hdmr.org\/d\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/hdmr.org\/d\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/hdmr.org\/d\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/hdmr.org\/d\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=1167"}],"version-history":[{"count":0,"href":"http:\/\/hdmr.org\/d\/index.php?rest_route=\/wp\/v2\/posts\/1167\/revisions"}],"wp:attachment":[{"href":"http:\/\/hdmr.org\/d\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=1167"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/hdmr.org\/d\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=1167"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/hdmr.org\/d\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=1167"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}