- 0.ã¯ããã«
- 1.å¿æ§ã
- 2.åé¡æ
- 3.ã³ã³ãã¹ãéå§
- 4.ãµã³ãã«ã³ã¼ããåãã
- 4.èå¯ï¼ã³ã³ãã¹ã1æ¥ç®ï¼
- 5.èå¯ï¼ã³ã³ãã¹ã2æ¥ç®ï¼
- 6.æåã®æåº
- 7.ã¸ã°ã¶ã°ã«è¦ã
- 8.ã³ã³ãã¹ã3æ¥ç®
- 9.180度å転ãå ¥ãã
- 10.ããç¼ããæ¢ãé¢æ°ã®è¦ç´ã
- 11.åæ解ã®ãã¹ããã§ãããã£ã
- 12.åæ解ã®æ¹åãèããï¼èã®é·ããä¹±æå±±ç»ãï¼
- 13.ããç¼ãæ¢ç´¢ã®è©ä¾¡é¢æ°ãèããããã¾ãããããè¿åé·ç§»ãæ¹åãã
- 14.ãã¸ã¥ã¢ã©ã¤ã¶ã®ä½æ
- 15.ã³ã³ãã¹ã9æ¥ç®ï¼åæ解ã®èã®é·ãã®èå¯ï¼
- 16.ã³ã³ãã¹ã10æ¥ç®ï¼æ ¹ã®ç§»åã«ã¤ãã¦ã®èå¯ï¼
- 17.ã³ã³ãã¹ãæçµæ¥
- 18.ãçµããã«ãããã®æªããã
- 18.çµããã«
- 19.æçµçµæï¼2024å¹´10æ16æ¥æ´æ°ï¼
0.ã¯ããã«
ã¯ããã¾ãã¦ããããã¯ãä¹ ãã¶ãã§ãã競ããæ´4å¹´10ãæã®ããã§ã§ãã
ä»åã¯ã ãã¨ã¿èªåè»ããã°ã©ãã³ã°ã³ã³ãã¹ã2024#10ï¼AtCoder Heuristic Contest 038ï¼ã«åå ãã¾ãããéå¬æéã¯2024å¹´10æ4æ¥(é)19:00ãã2024å¹´10æ14æ¥(æ)19:00ã¾ã§ã®11æ¥éã®é·æã³ã³ãã¹ãã§ãã
ãã®åå è¨ã¯ã³ã³ãã¹ãéå¬ä¸ã«ãªã¢ã«ã¿ã¤ã ã§æ¸ãã¦ãã¾ããä»åã¯ãã¤ã«ãå¢ãã¦ç¬ãè¨ãå¤ããªã£ã¦ããã®ã§èªã¿ã¥ããããããã¾ãããããã§ããã®åå è¨ãå ¬éããã®ã¯ãèªãã æ¹ã«å°ãã§ããã¥ã¼ãªã¹ãã£ãã¯ã»ã³ã³ãã¹ãã®æ¥½ãããæãã¦ãããããã¨æã£ã¦ããããã§ãããããèªãã§èªåãã³ã³ãã¹ãã«åå ãã¦ã¿ããã¨æã£ã¦ãã ããæ¹ãããã°ãã¨ã¦ãããããæãã¾ãã
1.å¿æ§ã
ãããããã¨ã
- æ¥æ¬èªã³ã¼ãã£ã³ã°ããã
- ãã¸ã¥ã¢ã©ã¤ã¶ãä½ã
æ¬å½ã«æ¬å½ã«ä¸ä½ã«è¡ãããã
2.åé¡æ
åé¡æã¯ãã¡ãã
-
æ¦è¦:
- é«æ©ç¤¾é·ã¯ãäºæ¬¡å ã°ãªããä¸ã§ããç¼ããæå®ããããã¹ã«ç§»åãããããããã¢ã¼ã ãéçºãã¦ããã
- ããããã¢ã¼ã ã¯é¢ç¯ã¨æå ãé ç¹ã¨ããæ¨æ§é ã§è¡¨ç¾ãããã
- ä¸åº¦ã®æä½ã§ãããããã¢ã¼ã å ¨ä½ã®ç§»åãé¢ç¯ã®å転ãæå ã§ã®ããç¼ãã®æ´ã¿ã»é¢ããåæã«è¡ããã¨ãã§ããã
- æä½ã¿ã¼ã³æ°ãã§ããã ãå°ãªããã¦ããã¹ã¦ã®ããç¼ããç®çå°ã«ç§»åããããã¨ãç®æ¨ã
-
å ·ä½çãªå¶ç´:
- ã°ãªãããµã¤ãºã¯ ï¼ï¼ã
- ããç¼ãã®æ°ã¯ åï¼ï¼ã
- ããããã¢ã¼ã ã®é ç¹æ°ã¯ 以ä¸ï¼ï¼ã
- 辺ã®é·ã 㯠ã®æ´æ°ã
- æä½ã¯æ大  ã¿ã¼ã³ã
- ããããã¢ã¼ã ã®åæç¶æ ã¯æ ¹ã®ä½ç½®ã¨å ¨ã¦ã®è¾ºãå³æ¹åã«ä¼¸ã³ãç¶æ ã
- ä¸åº¦ã®æä½ã§ã以ä¸ãåæã«è¡ããï¼
- ããããã¢ã¼ã å ¨ä½ã®ä¸ä¸å·¦å³ã¸ã®1ãã¹ç§»åã
- é¢ç¯ã軸ã¨ããé¨åæ¨ã®90度å転ã
- æå ã§ã®ããç¼ãã®æ´ã¿ã»é¢ãã
-
ã¹ã³ã¢ãªã³ã°:
- ãã¹ã¦ã®ããç¼ããç®çå°ã«å°éããå ´åãæä½ã¿ã¼ã³æ° ã絶対ã¹ã³ã¢ã
- ä¸é¨ã®ããç¼ããæªå°éã®å ´åã絶対ã¹ã³ã¢ã¯ ï¼Â ã¯å°éããããç¼ãã®æ°ï¼ã
- 絶対ã¹ã³ã¢ãå°ããã»ã©è¯ãã
3.ã³ã³ãã¹ãéå§
åé¡æãèªã¿ã¾ããä»æã£ã¦ãããã¨ã§ãã
- é常ã¯ï¼ãã¹ãã¤ããåããªããã©ãå転ã ã¨å¤§ãã移åã§ããã
- ä¸åº¦ã«è¤æ°ãåãããããããããã¢ã¼ã ã90度ã180度ã270度åãããã¨ãèããã
ã³ã³ãã¹ããå§ã¾ã£ã¦15åã»ã©ãçµéãã¦ãã¾ãããé ä½è¡¨ãè¦ã¾ãã5ä½ä»¥ä¸ã¯ãµã³ãã«ã³ã¼ãã¨æãããå¾ç¹ã§ãã
4.ãµã³ãã«ã³ã¼ããåãã
ãµã³ãã«ã³ã¼ããå®è¡ãã¦ãã¸ã¥ã¢ã©ã¤ã¶ãè¦ã¾ããã©ã³ãã ã§åãã¦ãããã©ãä½ããã¦ããªãï¼
4.èå¯ï¼ã³ã³ãã¹ã1æ¥ç®ï¼
ãã¤ãã®ããã«ACããã³ã¼ããæ¸ããããªããã©ããã£ã¨ææ ¢ãã¾ãã
- ï¼ãã¹ãã¤åããã°ãããç¼ããï¼åãã¤åãããã¨ã¯å¿ ãã§ãã
æä½éACããã³ã¼ãã¯æ¸ããã¯ãã ã¨æã£ã¦èå¯ããã¾ãã
æ¨å ¨ä½ãä¸ä¸å·¦å³ã®ã©ããã«ï¼ãã¹åãããé¨åæ¨ãå転ããããã¨ã§ãã©ããªç¯å²ã«ç§»åã§ããã®ããèãã¾ããå ¨é¨ãèããªãã¦ãã©ããä¸æ¹åãèããã°ããã¯ãã
èãã¦æ°ãä»ããã®ã¯ãæ°´å¹³æ¹åãåç´æ¹åã¯ï¼ï¼0.5LENï¼æ¨ã®ç´å¾ï¼åãã¦ãæãæ¹åã¯ï¼ï¼LENï¼æ¨ã®ç´å¾ï¼åããã®ã§æãæ¹åã®ç§»åããå¾ã ã¨ãããã¨ã
ä¾ãã°æ¨ã®ç´å¾ãï¼ã®ã¨ãã
ãªãã移åãæ¸ãã¦ã¿ããã©æã£ãã¿ããã«åããªãã®ãããé¨åæ¨ãï¼ä»¥ä¸ãåããã¨ãªãã¨èµ¤ä¸¸ã¯å¸¸ã«ï¼ãã¹ããåããªãæ§åã
ãªãã»ã©ã
- é¨åæ¨ã90度å転ãããã®ã大ããªåãã§ãã以å¤ã¯å°ããã
- ç®çå°ã«æåããããç¼ãããã£ããåãããªããã¨ã«ãã¦ã¿ãããã
- ä¸ç·ã«åããã¨è¯ããªãã¨ãã¯ãããããseed8ãè¦ãã絶対ããç¼ããã¤ãã¿ãªãã移åããæ¹ãããããã
ããããããCodingameï¼Fall Challenge 2024ï¼ã¨ã¡ãã£ã¨ä¼¼ã¦ããã
Mï¼ããç¼ãã®æ°ï¼ã¯22ãã450ãããååãããç¼ãã ã£ãããããªãã®æ°ãæåããä¸è´ãã¦ãããã
ãã¼ãæ ¹ã®åæä½ç½®ã決ãããããã ãå¤ç¹ã¹ã¿ã¼ãã試ããªãã¨ã
2åéã¹ãã®ãã2åéã¼ãã
ãã£ã±ãæ ¹ã§ï¼åãã¤éãã§ã¿ãï¼
- ããç¼ãããªããã¸ã·ã§ã³ãè¦ã¤ããã
- ããç¼ããããå ´æãè¦ã¤ããã
- ããç¼ããããå ´æã«è¡ã£ã¦ããç¼ããã¤ããã§ããç¼ãããªããã¸ã·ã§ã³ã«è¡ãã
ã¨ãããããããªæ¨ã«ãããããªãããç¼ãã4åã¤ããããã
é ä½è¡¨ãåã³è¦ã¾ãã
ããä½ã貪欲ããã¦ããã®ããªããµã³ãã«ã³ã¼ãã®ç¸å¯¾ã¹ã³ã¢109,408,603ã®81åã»ã©ãå¾ã®ããã«ã¨ããããè¨é²ãã¾ãã
5.èå¯ï¼ã³ã³ãã¹ã2æ¥ç®ï¼
2æ¥ç®ã®æã§ããé ä½è¡¨ãè¦ã¾ããUSAããããã³ãããããã
ãã¼ãåé¡é£ãããªã¼ãé ãåãã¾ããã
- é¢ç¯ç¹ï¼é¨åæ¨ï¼ã§åãããããã«é¢æ°ãè¨è¨ããã
å¿ è¦ãªã®ã¯
- é¨åæ¨ã®è¦ªã®åº§æ¨
- é¨åæ¨ã®åº§æ¨ã°ã«ã¼ã
- å転æ¹å
ããï¼æ¸ãã¦ã¿ãããããªã«é£ãããªãï¼
- é¨åæ¨ã®ã°ã©ãã管çãã
å¤æ´ã®ãªããã®ã¯ã°ãã¼ãã«ã«ããã¦ãã¾ããããªãæ¯åå¼æ°ã§å ¨ã¦ã渡ãã®ã¯é¢åã ããã
- é¨åæ¨ã®ã°ã«ã¼ãããã¾ã管çããã
ã¨æã£ããã®ã®èå¯ã¯é²ã¿ã¾ããã
ã©ãèãã¦ã180度å転ãå¼·ããªã¼
ã ã£ã¦é¢ããå ´æã2æã§å ¥ãæ¿ããããããã
V=5 ã®ã¨ããå ã®ä½ç½®ãã2æã§8ãã¹ç§»åã§ããã
ãããããã2æã§8ãã¹ä»¥å¤ã«è²ã åããããªãæãæ¹åãã²ãå½¢ã®å³ååã¯1æã§ãå·¦ååã¯2æã§è¡ããï¼å ã®ããç¼ãã®ä½ç½®ãé»è²ã®ã¨ãï¼ã
ã¾ã¨ããã¨ãããªæãããããããªã移åãç°¡åã«ã§ãããã180度å転移åããã¦æãã¦ããå ´é¢ãã¼ãã£ã½ãã
ãã®èå¯åã£ãï¼
æãã®éä¸ã¯é¨åæ¨ãå転ããã¦ããã®ã§æ»ãæä½ããããããªãã
å®è£
æ¹éãã¾ã¨ã¾ããã«ãã ãã ã¨éããã¦ãã¾ãã
æ°æã¡ãèãã¦ãã¾ãããï¼é±éã®ã³ã³ãã¹ããªãã ããã¨èªåãå±ã¾ãã¾ãã
- ããã«ããããªãåé¡ãåºãã¦ãã
- ãã解ããã¨æããª
åªæã®ããã«ã¨ãªãã¦æ°æã¡ãè½ã¡çãã¾ããæ°æã¡ãè½ã¡çããå¾åã³èå¯ãé²ãã¾ãã
- åãæ¹ã調ã¹ã
æ°æã¡ãé¼èãã¦ãã¸ã¥ã¢ã©ã¤ã¶ãéãã¾ããæåã§çããæ¸ããã¨ã«ãã¾ããã
æ¨ãä½ãã¾ãã
- 親ã¨é·ããæ¸ãã
- é¨åæ¨ãå転ãããã
- ããç¼ããã¤ããã§å転ã
- ããç¼ããé¢ãã
- é¨åæ¨ãå転ãããç¼ããã¤ããã
- å ¨ä½ã§ä¸ã«ä¸ãã£ãã¦ãããç¼ããé¢ãã
ä¾ãè¦ãã®ãã¸ã¥ã¢ã©ã¤ã¶ã«æã§æ¸ããåºåãè²¼ãã¾ãã
4
0 1
0 1
2 1
1 1
..R..P.P
.LL..P.P
.L...P..
D....P..
ããããªãã»ã©ã
æ¨ã®æ§é ä½ãä½ããã
ããã¾ã§æ¥ããåããã®ãæ¸ããªãã¨ãããããªãã
é·ãVã®æãæ²ãããªãæ¨ãæ¸ããã
ããï¼é·ãã¯ï¼ä»¥ä¸N-1ã ã£ãããããé·ãæ¨ãä¸æ¬ä½ã£ã¦ã¿ãï¼é·ãã®éãæ¨ãVæ¬ä½ãã°ãããã¼ã
ãããä½ãã¢ã«ã´ã®åé¡æãæµ®ããã ãªã
ãããè¦æã ã£ããã¤
ãã®åé¡ã®ãã¨ã§ã¯ãªããã©ä½ããã³ãã«ãªããããããªãããããã«åé¡ãè²¼ãä»ãã¦æ¬¡ã«ããããã¨æãã¾ãã
ã©ããã£ã¦åããããããã®ããèãã¾ãã
- å¶æ°æ®µã端ãããæé¤ããæãã
æåã§ã³ã¼ããæ¸ãã¦ãã¸ã¥ã¢ã©ã¤ã¶ãè¦ã¾ãããããªæãã«ãã¦ãããããªã
ãã¸ã¥ã¢ã©ã¤ã¶ãåããã¦ãããé¢ç½ããªã£ã¦ãããããæ©ãåããã®ãä½ããããªã¼ã¨ããæ°æã¡ã«ãªãã¾ããã
6.æåã®æåº
å¿ è¦ãªã®ã¯
- æ ¹ã®ä½ç½®ï¼ï½ãï½åº§æ¨ï¼
- èã®ä½ç½®ï¼ï½ãï½åº§æ¨ï¼
ã»ããé¢æ°ã
- å転ããå¾ã®åº§æ¨
ãã³ããã¿ã³è·é¢ã¯æ ¹ï¼å ¨ä½ï¼ã§ç§»åããã¨ãã®ã³ã¹ãã
移åããªããããå転ã¯ã³ã¹ãï¼ã
- ããç¼ãã®å ´æã調ã¹ã
- ããç¼ããç½®ãããå ´æã調ã¹ã
- èãããç¼ãã«å±ãããèãããç¼ããããå ´æã«å±ãã¾ã§ã®è·é¢ã¨æçã«ã¼ããé¢æ°ã§è¿ãã
TSPã«ã§ããã°ãããã©ã¨ãããã貪欲ã§ã
ã¹ã¿ã¼ãã¯(0,0)ã«ãããã©ã
- æåã®ããç¼ãã«èãå±ãå ´æããã¹ã¿ã¼ãããã°ããã®ã§è¨é²ãã¦ããã
ãã£ã¨ã«ã¼ã«ãåç´åããã¨é ã®ä¸ã§ãããã声ãèããã¾ãã
ãã å·¦å³ãå ¥ãæ¿ããã ãã§ããæ°ãããã
ãã¨ãã°é·ãï¼ï¼ï¼ï¼ï¼ï¼ï¼ï¼ï¼ã®ï¼åã®èãã¤ãããªããï¼åãã¤çä»ãããã
ãããã§ããæ°ããã¦ããã
ãã¸ã¥ã¢ã©ã¤ã¶ãè¦ãªããã§ããããèãã¾ãã
ãã¼ãã足ããªãã¨ãã«ã©ãããããé£ããã
- ããç¼ãããã£ããã¨ããããã¤ããã
- åãããå ´æãç½®ãããå ´æãªãç½®ããããã§ãªããªãæã£ã¦ããã
- ããç¼ãããªãå ´æããã£ãããææ°ãå°ãªãã¨ããã調ã¹ã¦ããç¼ãããã£ã¦ããã
å ¥åºåç¨ã®æ§é ä½ãæ¸ãã¦ãå転ãããé¢æ°ãæ¸ãã¾ããã
ãã¼ããèã管çããæ§é ä½ã®é ç®ãã©ãã©ãå¢ãã¦ããã
ä»ãããªæãã
- èã®ID
- èã®x座æ¨
- èã®y座æ¨
- èã®é·ã
- èã®æ¹å(0: å³, 1: ä¸, 2: å·¦, 3: ä¸)
- ããç¼ããæã£ã¦ãããã©ãã
åæè¨å®
- èã®é·ãã¯IDã¨åãé·ãã«ãã
ãªãã»ã©ãæåã®æ¨ã¯æ°´å¹³ã«ä¸¦ã¶æ¨¡æ§ã
ãã¸ã¥ã¢ã©ã¤ã¶ãè¦ãªãããããç¼ããã¤ããã ããããç¼ããç½®ãããã§ãã¦ãããã確èªãå°ããã¤åãããã«ãªã£ã¦ãã¾ããã
ï¼æå ï¼æå ã調ã¹ã¦å転ã§ããã°ããªãè¯ãããã
ãã£ã¨é¢ç½ããªã£ã¦ããã
æ¨ãªãã¦é¢åã ã¨æã£ã¦ãããã©ã竹串ã«ããç¼ããåºãã ããªãã¾ãã§ãããã
ããã¨è¯ãããã«è¦ãããªã¼ã
ã¹ãã¼ãæãããã
ã©ããªãã ããã
ä¸åº¦åºãã¦ã¿ãããªã£ãã®ã§æåºããã¾ããç¡äºã«ACãã¾ããã
ç¸å¯¾ã¹ã³ã¢ã¯ãµã³ãã«ã³ã¼ã20,296,533ããã»ãã®å°ãè¯ãå¾ç¹ã§ããã
ä»ã¯180度å転ãã§ãã¦ããªãããå ¨é¨åãããã¦ãã¾ããã
伸ã³ããããã£ã·ãã
åã£æãããé£ããã¦ã¤ããã£ããã©ãã³ã¼ããåãå§ãããä¿ç¶ããããããªã£ã¦ãã¾ãããé£ãããã¨ãã§ããªãã¦ãä¸ä½ãç®æããå¿ã«èªãã¾ãã
ä»ã®çµ¶å¯¾ã¹ã³ã¢ã6644000ã§ããã®ãã¨èªåãç°¡åã«åãã絶対ã¹ã³ã¢ã®æ大ãN*Nã50ã±ã¼ã¹ãªã®ã§50åããã¨45000ã¨ãã絶対ã¹ã³ã¢ãè¨ç®ã§ãã¾ããå²ãç®ãããã¨147åã«ãªãã¾ããä»ã®ç¸å¯¾ã¹ã³ã¢ã147åããã¨4,683,849,765ãç¾å¨ã®ç¸å¯¾ã¹ã³ã¢ã§63ä½ç¸å½ãä»ã®æãã ã¨ãã®åã®ã¹ã³ã¢ã«ã¯ã§ããã¨æãã®ã§40ä½ãããã®é ä½ã¯çããã¯ãã ã¨æãã¾ãã40ä½ã«ãªãã°é»ããã©ã«ãªãã¾ãã
ãããååãããã
ãã®ããããããæããã©ããã£ã¦ä¼ãããè¯ãã®ã ããã
ã§ãããããããªãã¨ããå¸æã®ãããªä½ããè¸ãæºããã¨ãã®ããããã
ã¢ã«ã´ã§ã²ããããã¨ãã«ãä¼¼ã¦ããã®ã ãã©ãããã¡ãã£ã¨ä½ãä¸ãã¦ããæãããæ°ããã¦ããã
ä»åAHCã®ãã¼ãæ²ã¯ããããã£ããããªãã
7.ã¸ã°ã¶ã°ã«è¦ã
æ ¹ã¯å ¨ã¦ã®ãã¹ãéãã¾ããï¼0,0ï¼ããã¹ã¿ã¼ããã¦ãå³ç«¯ã«è¡ã£ããä¸ã«ï¼ãã¹ä¸ããããã®å¾ã¯å·¦ç«¯ã«é²ã¿ã¾ãã左端ã«æ¥ããã¾ãï¼ãã¹ä¸ãã£ã¦å³ã«è¡ãã¾ãããããªãµãã«ã¸ã°ã¶ã°ã«æ ¹ã移åãã¾ãããã³ã¼ããæåºãã¾ãã
ï¼0,0ï¼ããã¹ã¿ã¼ãããæ ¹ãï¼N-1,N-1ï¼ã«å°éããããå æ¥ãéãå¼ãè¿ãã¦ï¼0,0ï¼ã«æ»ãã¾ããå ¨ã¦ã®ãã¹ãæ ¹ãï¼åéãã³ã¼ãã«ãã¾ããã
é ä½è¡¨ã®ãããã¯c7c7ããã«å¤ãã£ã¦ãã¾ããã
8.ã³ã³ãã¹ã3æ¥ç®
ç¿æ¥ã®æã§ããé ä½è¡¨ã®ããããçªãæãã¦ãã¾ãããããããï¼ãã®ã¹ã³ã¢ã¯ç¸å¯¾ã¹ã³ã¢ã®æºç¹ã§ãå ¨ã¦ã®ãã¹ãã±ã¼ã¹ã§1ä½ãåã£ã¦ããã¨ãããã¨ã示ãã¦ãã¾ããï¼
ãã¦ãï¼N-1,N-1ï¼ããå§ã¾ã横æ¹åã®ã¸ã°ã¶ã°ã¨ï¼0,0ï¼ããå§ã¾ã縦æ¹åã®ã¸ã°ã¶ã°ã追å ãã¦ä¸çªè¯ãã¹ã³ã¢ãæåºããã³ã¼ãã«ä¿®æ£ãã¾ããã絶対ã¹ã³ã¢ã¯ã ãã¶è¯ããªã£ã¦ãã¾ããããã¼ã«ã«ã§å®è¡ãã100ãã¹ãã±ã¼ã¹ä¸81ã±ã¼ã¹ã§ã¯å ¨ã¦ç®çã®ä½ç½®ã«ããç¼ããç½®ããã¨ãã§ãã¦ãã¾ãã
ã¾ã å ¨é¨ç½®ãã¦ããªãã®ãseed2ã
ããç¼ãã®ä¸²åºããç¡é§ãªåãããã¦ãã¾ãããã¼ã©ã¼ã¿ãããªåããå¤ãã¦ã¿ããããªã
ãããã渦巻ãã«ãã¦ã¿ã¾ããã
ãã¼ããå¾®å¦ã
å´ä¸ãã¾ãã
ç´ ç´ã«è¡ã£ããæ¥ãããããããªã
- ããç¼ããåãã«è¡ã
- ããç¼ããç½®ã
ãªããªãæã£ãããã«åãã³ã¼ããæ¸ãã¾ãããä½ã¨ãããã£ã½ãåãããã«ãªã£ãã®ã§æåºãã¾ãã
seed0ã ãã¨ã¦ãè¯ããªãã以åã®ï¼åã®ï¼ãããã®ã¹ã³ã¢ã«ãªãã¾ãããå¶ç¶ãã¾ãã¯ã¾ã£ã¦ããæããä»ã®seedã§ã¯ãããªãµãã«ãã¾ãããã¾ããã
ã¤ããã ãé¢ãããããã¨ã以å¤ã®ãã¸ã·ã§ã³ãããæãã«ããã¨è¯ãã¹ã³ã¢ãåºãã¨ããã®ãããã£ã¦ãããããã2æå èªã¿ã¨é¢ä¿ãããã¨æã£ã¦ããã®ã ãã©ãã©ããããè¯ãã®ãã¯ã¾ã ãããã¾ããã
ã¨ãããããããããªãã¿ã¼ã³ãå ¨é¨è©¦ãã¦ä¸çªè¯ãã¹ã³ã¢ãåºããã¨ã«ãã¾ããããã¹ãéãé ãå¤ããããèã®åããå¤ããããã¦ãå ¨é¨ã§6ãã¿ã¼ã³ãä½ã£ã¦ãã¾ãã
100ãã¹ãã±ã¼ã¹ã®ãã¡ãå ¨é¨97ã±ã¼ã¹ã¯å ¨é¨ç½®ããã¨ãã§ããããã«ãªãã¾ãããã¹ã³ã¢ãN*Nããå°ããæ°ã«ãããã¨æã£ã¦ãã¾ããéæã§ãã¦ããã®ã¯33ã±ã¼ã¹ã®ã¿ã
縦横ã«èµ°æ»ãã解æ³ãå ¥ãã¾ãã100ãã¹ãã±ã¼ã¹ã§ã¯å ¨ã¦ä¸¦ã¹ãããããã«ãªãã¾ããã絶対ã¹ã³ã¢ã¯ä¸ããã¾ãããç¸å¯¾ã¹ã³ã¢ã¯ã»ã¼å¤ããã¾ããã
å®è¡æéãä½ã«ä½¿ãã°ããã®ããªãã
éæ¢ãã©ã°ãã¤ãã¦180度å転ãã¤ãã¦ã¿ããã
ãã®å¾ã¯ä¸çªè¯ã解ã®æ¹åãæ®ãæéã使ã£ã¦ãããã
9.180度å転ãå ¥ãã
180度å転ãå ¥ãã¦ã¿ãã¨ãããç¼ããããå ´æãããç¼ããç½®ãå ´æãæ¢ãé¢æ°ããã°ã£ã¦ãããã¨ã«æ°ãä»ãã¾ãããããã§ããã°ã£ã¦ãããªãã«æ¹åãã¦ãã¦ãæåºãããã¨çµ¶å¯¾ã¹ã³ã¢ã58831ã«ãªãã¾ãããããããç¸å¯¾ã¹ã³ã¢ã¯å°ãä¸ãã£ãã ãã§ããã
10.ããç¼ããæ¢ãé¢æ°ã®è¦ç´ã
æ¢ãé¢æ°ã®ãã°ã£ã¦ããåå ããããã¾ãããæ ¹ã®ä½ç½®ããã§ãªãèã®ä½ç½®ãã調ã¹ã¦ãã¾ãããããä¸åº¦ããèãã¦æ¸ãç´ãã¾ããããã¦ãã¤ãã«ãããã°ãçµãã¾ããã
ãã¾ãæ¢ç´¢ã§ãã¦ããªãã£ãã®ã¯ä»ã®èã®åãã ãã§æ¢ç´¢ããã¦ãããã¨ãåå ã§ãããã ããéä¸ã§èãå転ãããã¨ã¹ã³ã¢ãä¸ä¸ãã¦ãã¾ããã
ã¾ãããã¾ãè¦ã¤ãããªãé¨åã¯ã©ã³ãã ã§ç§»åããããã¨ã«ãã¾ãã
100ãã¹ãã±ã¼ã¹ã§è©¦ããçµæã¯ãããã¾ã§ã®ååãããã®ã¹ã³ã¢ã«ãªãã¾ããã
ãã£ããï¼
æåºããã¾ãã
çµæã¯50ã±ã¼ã¹ä¸7ã±ã¼ã¹ãTLEãã¦ãã¾ãã¾ããããããç¸å¯¾ã¹ã³ã¢ã¯7,139,343,218 ã«ãªãã139ä½ã«ãªãã¾ãããã¤ãã«æéãæãåºããæ°ããã¾ããã
8å試ãã¦ãã解æ³ã®ãã¡ããã¹ãããªãã£ã4ã¤ã®è§£æ³ãæ¶ãã¾ããã
æéãè¨ã£ã¦å¶éæéå ã«ããã¾ã£ã¦ãããã¨ã確èªãã¾ãã
ç¤é¢ã大ããã¦ãVï¼èã®æ°ãå¤ãï¼ã¨ãã§ã2ç§ä»¥å ã§ãããä»åã®å¶éæéã¯3ç§ãªã®ã§ãæ®ãã®æéã¯ãã®è§£ãæ¹åããæéã«ä½¿ãããã¨æãã¾ãã
100ãã¹ãã±ã¼ã¹ä¸83ã±ã¼ã¹ã§N*N以ä¸ã®ã¹ã³ã¢ã«ãªãã¾ããã
11.åæ解ã®ãã¹ããã§ãããã£ã
ããã¦æºãæãã¦åæåºããã¾ããã
ããã¾ãTLEãã¦ãããç¤é¢ã大ããã¨ãã¯è§£æ³ãï¼ã¤ã«çµããããªãå ã»ã©ããã¯æ¸ãã¾ããã50ã±ã¼ã¹ä¸3ã±ã¼ã¹ã§TLEããã®ã§çµ¶å¯¾ã¹ã³ã¢ã¯ã¾ãã0ã§ãã
ç¸å¯¾ã¹ã³ã¢ã¯7,709,151,408ã«ãªããé ä½ãã»ãã®å°ãä¸ãã732人ä¸136ä½ã«ãªãã¾ããã
ãã¼ãããã¨ã¡ãã£ã¨ãTLEã®åå ã¯è¯ãæ¢ç´¢å ãè¦ã¤ãããªãã£ãã¨ãæ ¹ãã©ã³ãã ã§ç§»åããã¦ããã®ã§ãããåæ³æã«éãã®ãå¿ãã¦ããããã§ããã
TLEã解æ¶ããããã解æ³ã2åã«çµãã¾ãããããã¨å®è¡ãããã«çµããããã«ãªãã¾ãããã¾ããã¹ã³ã¢ãã»ã¼å¤ãããªããã¨ããããã¾ããã
æåºå¶éã30åééãªã®ã§ãåæåºã§ããã¾ã§ãã¨20åéããã¾ãããã®éä¼æ©ãããã¨ã«ãã¾ãã2024å¹´10æ7æ¥ã®23æãã³ã³ãã¹ã4æ¥ç®ã®å¤ã§ããã
seed1ã®ãã¸ã¥ã¢ã©ã¤ã¶ãããæãã«180度å転ã使ãã¦ããæ°ããã¾ãã
30åå¾ ã£ã¦æåºããã¾ãããä¸ç¬ã§çµããã¾ããã絶対ã¹ã³ã¢ã¯23616ã«ãªãã¾ãããç¸å¯¾ã¹ã³ã¢ã¯8,041,815,927ã«ãªãã133ä½ã«ãªãã¾ããããããä¸ãã£ãï¼
ããã§ãç¸å¯¾ã¹ã³ã¢ã¯ãããã¨8åã®éããããã¾ãã
ãããã®è§£æ³ã¯ã©ããªã£ã¦ãããã ããï¼ï¼
ã³ã³ãã¹ããçµãã£ã¦è§£æ³ãèãã®ã楽ãã¿ã«ãªãã¾ããã
12.åæ解ã®æ¹åãèããï¼èã®é·ããä¹±æå±±ç»ãï¼
ä»æã£ã¦ããã®ã¯èã®é·ãã®çµã¿åãããå¤ãããã¨ãããã¯ç°¡åã«ã§ããããç¤é¢ã®å¤§ããã«å¯¾ãã¦èã®é·ããé·ãããã¨ãã¯ä½¿ãã¥ããããã«æãã¦ãã¦ãç¤é¢ã®ååãããã¾ã§ã®é·ããè¯ãããã«æãã¦ãã¾ãããã¨è©¦ãã¦ããªãã£ãåãé·ããè¤æ°æã¤ã¨ãã
次ã¯æ¢ãã¨ãã®æ¡ä»¶ãè©ä¾¡é¢æ°ã«ãããã¨ãä»ã¯è·é¢ãä¸çªè¿ãè¡åããã¦ãããã©ããã¼ã¿ã«ã§çãæ¹ãè¯ãã®ã§ããã¬ã¤ã¢ã¦ããããããä¸åº¦ã«ã¾ã¨ãã¦æä½ã§ããåæ°ã¿ãããªãã®ãè©ä¾¡å§ã«ããã¨ããè¡ã£ããæ¥ããããã¨ãã«ããã«ãã£ãã¤ãããã§ããªããã¨èãã¦ãã¾ãã
ã³ã³ãã¹ã5æ¥ç®ã®æã§ãã
é ä½è¡¨ã®ãããã®ã¡ã³ãã¼ã大ããå ¥ãæ¿ãã£ã¦ãã¾ãããã¡ã³ãã¼ããä½ã解æ³ãæ¨è«ã§ããªããã¨æãã¾ãããå¼·ã人ãã¡ãªã®ã§ä½ã§ãã§ãããï¼ããããªãã¨ãããã¨ï¼
ãã¦ãç§ã100ä½å°ã«ããã®ã§ç§ãé ä½è¡¨ã«è¦ã¤ãã人ã¯èå¯ãããã°ããã¨æã£ã¦ããã¯ãï¼å®éãã®éããªã®ã§ããï¼ãããã°ããã¿ããªãèªåãããã°ãã¾ãï¼
ã¾ãã¯æéå ã«ã©ã³ãã ã«èã®é·ããå¤ãã¦çããåºãã¦ã¿ããã¨ã«ãã¾ãã
ãã¡ããã¡ãè¯ããªã£ã¦ãï¼
ãã¼ã«ã«ã§10ã±ã¼ã¹ã»ã©è©¦ãã¦åºåã確èªããã¨å¾ ã¡ãããã«æåºãã¦ãã¾ãã¾ããã
æåºä¸ã«ãã¼ã«ã«ã®åºåã確èªãã¾ãã
seed2ã®ãã¸ã¥ã¢ã©ã¤ã¶ã§ãã659ããã£ã¦ããææ°ã266ã«ãªãã¾ãããé·ãèã®æ¹ãè¯ãããã§ãã
ãããã¾ãTLEãã¦ãã¾ãã¾ããã
ç¸å¯¾ã¹ã³ã¢ã¯æåºåã®144ä½ã7,888,293,701ãã113ä½ã10,525,322,748ã«ä¸ããã¾ããã
ãã£ããã¼ï¼
æããã¬ãããã¼ãºãåºã¾ãããã¤ããã楽ããã
æã¯ããã¾ã§ã
ä»ãããä»äºã§ãã
ãæ¼ä¼ã¿ãå®è¡æéããã¾ãã«è¨æ¸¬ãããã¨ã«ãã¾ããæéã2.5ç§ã§ããããã¨ã«ãã¾ããã
ç¡äºACãã¾ããã絶対ã¹ã³ã¢ã¯ãã¼ã«ã«ã®100ãã¹ãã±ã¼ã¹ã試ãã¦æãã¦ãã¾ããããããªãä¸ããã¾ãããããããã
é ä½ã¯107ä½ã«ãªãã¾ãããããå°ãã§2æ¡é ä½ã§ãã
ããã°ããï¼
13.ããç¼ãæ¢ç´¢ã®è©ä¾¡é¢æ°ãèããããã¾ãããããè¿åé·ç§»ãæ¹åãã
- å¾ããã¦ããã®ãè©ä¾¡ãã
- ä¸åº¦ã«ããããåããã¦ãã
- é ãã®ãã®ãåããã¦ãã
å ã«æ¢ç´¢å¾ã®åè©ä¾¡ã®ç§»åæ¹åãã©ã³ãã ã«ãã¾ãããã¾ãã¡ã§ããã
è©ä¾¡é¢æ°ãæ¸ãã¦ã¿ã¾ãããã¾ãããã¾ããããã¼ãã
ã¯ã¾ã£ã¦ããã®ã§ãã¸ã¥ã¢ã©ã¤ã¶ãè¦ããã
ã¹ã¿ã¼ãå°ç¹ãå¤ãã¦ã¿ãããã
èã®é·ããï¼ãæã ãã©ã³ãã ã§å¤ããå±±ç»ãã«ãã¦ã¿ããã
éè¤ãåé¤ãã¦ããªãã£ãã®ã§ãããã
ä½ãåãé·ããï¼ã¤ãããåãé·ããï¼ãããã¨ä½ããããã¨ããï¼å ¥ãæ¿ããï¼åã§ã§ããï¼
æ¯åãã®å ´æã§ææ¾ãã¨è¯ãï¼
ãã¼ãä½ãããããããªã
æä½ 3 ã®ä¸ã§ã¯é ç¹çªå·ã®å°ããæå ããé ã«å¦çãè¡ããã
ï¼åé¡æä¸ããå¼ç¨ï¼
ããã§ãããããã©ããããã¨ãã§ããã®ããªãAãBã«ç½®ãã¦ãBãæã£ã¦Cã«ç§»åããã¼ããæã¡æ¿ããã§ããã¨ã©ããªè¯ããã¨ãï¼ãããããæä½é ãéè¦ãªã®ãã
ãã¼ããã£ã±ã180度å転ãï¼åã§ã§ãããã
ããã¯å¼·ããï¼
ä¸æ¦ç½®ãã¦ããã¦ãã¹ã¿ã¼ãå°ç¹ã試ã
è¯ãåè£ã®ã¹ã¿ã¼ãå°ç¹ã試ããããªã
ãããåé¢ãããã
ãã¾ããããªãæéãç¶ãã¾ãã
å·éã«ãªãããéé²ã«è©¦ãã®ã§ã¯ãªãã
ããã¾ã§ã¯å ¨é¨ã®èã®é·ããå¤ãã¦ãã¾ãããä»ã®ãã¹ãã®ç¶æ ããï¼åã ãèã®é·ããå¤ãããã¨ã«ãã¾ããæåããããããã¹ãã§ããã
- èã®é·ããï¼åãã¤ã©ã³ãã ã«å¤ããå±±ç»ãããã¾ãã
100ãã¹ãã±ã¼ã¹ã試ãã¨ãä¹ ãã¶ãã«ãã¹ããæ´æ°ãã¦ããã®ããããã¾ãããæåºããã¨çµ¶å¯¾ã¹ã³ã¢ã¯13895ã«ãªãã¾ãããç¸å¯¾ã¹ã³ã¢ã¯12,135,490,095ã«ãªãã778人ä¸109ä½ã«ãªãã¾ããã2æ¡é ä½ã«ãªãããã§ãªããªãããã©ãããæéãç¶ãã¾ãã
seed0ã§ã¯ã¹ã³ã¢56ãåºã¾ããã
- è¡ã£ããæ¥ãããç¡é§ãªã®ã§ã端ããå¦çãããã¨ãèããã
- ä»ããã«ã¼ãã®swapãç¹ãå¤ããã§ããªãããèãã
14.ãã¸ã¥ã¢ã©ã¤ã¶ã®ä½æ
ä»äºãå¿ããã¦åãçµãæéãç¡ããååãã2æ¥çµã£ã¦ãã¾ããç¾å¨ã¯ã³ã³ãã¹ã7æ¥ç®ãæ¨ææ¥ã®å¤ã§ããã¾ããä½èª¿ãè¯ããªãã®ã§ãã»ãã®å°ãã ããã£ã¦å¯ããã¨æãã¾ãã
ããããã¯
- æ ¹ã®ã«ã¼ããæ¹åãã
ã®ãç®æ¨ã§ããä»ãããã¸ã¥ã¢ã©ã¤ã¶ã§ã¯ããããããã®ã§ããã¸ã¥ã¢ã©ã¤ã¶ãèªåã§ä½æãããã¨ã«ãã¾ããã
Google Colabã使ç¨ãã¦matplotlibã©ã¤ãã©ãªã使ç¨ããã³ã¼ããä½æãã¾ããã
seed0ã®æ ¹ã®ç§»åãæç»ãã¾ããããã£ã½ããã®ãã§ãã¾ããã
seed0ï¼ã¹ã³ã¢48ï¼ã®ãã¸ã¥ã¢ã©ã¤ã¶ã§ããã¾ã é£ç¶ã®æç»ããã¾ãã§ãã¾ãããããã£ã½ãæãã
å ¬å¼ã®ãã¸ã¥ã¢ã©ã¤ã¶ã¨ä¸¦ã¹ã¦ã¿ã¾ãã
æ£ç´çµæ§ããæãã®åãããã¦ãã¦æ¹åç®æããããããã¾ãããå¥ã®seedãè¦ããã¨ã«ãã¾ããseed1ã¨seed2ã§ãã
ä½ãç¡é§ããã
ã¾ãã¹ã¿ã¼ãä½ç½®ãç¡é§ãããã¹ã¿ã¼ãä½ç½®ã
- ä¸çªå·¦ä¸ï¼0,0ï¼ã«è¿ãããç¼ãã«ç½®ãããå ´æã«æçã§ããç¼ããç½®ããå ´æãæ¢ããããç¼ããç½®ãèã«ããç¼ããã¤ãããå ´æ
ã«ãããã¨æãã¾ãã
ãã¾ããããªãã®ã§ãã¹ã¿ã¼ãå°ç¹ãå®å ¨ãªã©ã³ãã ï¼xã¯å ¨ã¦ãyã¯vãå¼ããç¯å²ï¼ã«ãã¦å±±ç»ããã¾ããæåã¯ããç¼ããã¤ãããå ´æãè¯ãã¨æã£ã¦ãã¾ãããããã§ããªãï¼
âçµè«ãå¤ããã¾ããã§ããã
æè¨åãã¨åæè¨åãã両æ¹ã®é¸æè¢ãããã¨ããã¿ã¼ãªæ¹ãé¸æãã
ï¼ä»ã¯åæè¨åããæè¨åãã180度å転ã®é ã«é¸æãã¦ããï¼
æéãã®ã°ãããã¹ã³ã¢ã伸ã³ãã®ã§é«éåãèãã
- ã¹ã³ã¢è¨ç®ãç°¡ç¥åï¼æ¯åç¤é¢ãä¸è´ãã¦ãããè¨ç®ãã¦ããã®ãä¸è´ããæã®æ°ãæ°ãã¦ãã¦çç¥ãããã¨ã«ããï¼
- èã®é·ãã2以ä¸(N+1)/2以ä¸ã¨ãã
- æ¢ãã¨ãã®ã«ã¼ãã«éã¿ãã¤ãã¦ã©ã³ãã ã«é¸ã¶
- æ¢ç´¢ç¯å²ãç¾å¨ã®æ ¹ã®ä½ç½®ãã±N/2以å ã¨ãããã³ããã¿ã³è·é¢ã1.5N以ä¸ã¨ãã
Nã23以ä¸ã®ãã®ã®ã¨ãã¯ä½ãããªãã³ã¼ããæåºãã¦å¾ç¹æºã®ç¯å²ã調ã¹ã¾ãã
13,008,841,989ã6,950,641,389ã«ãªãã¾ãããNãå°ããã¨ãã®æ¹ãå¾æã ã¨æã£ã¦ãã¾ãããNãå°ããã¨ãã®æ¹ã3å²ãããè¯ãããã§ãã
Vã10以ä¸ã®ã¨ãã¯ä½ãããªãã³ã¼ããæåºãã¾ãã4,162,839,502ã«ãªãã¾ãããæã£ã¦ããã®ã¨ç°ãªããVãå°ããæ¹ãå¾æã®ããã§ãã1.7åã»ã©ã®éããããã¾ããããããªãã â¦
ããç¼ããç½®ãå ´æã端ãã決ãã¦ãã£ãæ¹ãè¯ãã®ããªãä½ã ã貪欲ã®è¯ã解æ³ãæãã¦ãã¾ããããã ãåã£ãå ´æã«å ¥åºåãããã®ã ãããããã¯ãããªæ°ããã¾ãããã¼ãããã£ã¨èãããã
åãã³ã¼ããåºããªããããã絶対ã¹ã³ã¢ãè¯ããªãã¾ãããæåºãã¨ã«å¤§ããã¶ããã³ã¼ããããã ãªãã¨æãã¾ãããé ä½ã¯ã»ã¼å¤ãããªãã£ãã®ã§åé¡ãªãã®ããããã¾ããã
- ãã¸ã¥ã¢ã©ã¤ã¶ãè¦ã
seed99ã®66ã¿ã¼ã³ç®ã§æ¬¡ã«å³ã«é²ãã°è6ã®ããç¼ããç½®ããã¨ãã§ãã¾ãããããä¸ã¸é²ãã§ãã¾ããåããã«å転ãããã ãã§ãè¯ãç¤é¢ã§ããæ¢ç´¢ãééã£ã¦ãããªãã¨æãã¾ãã
èã®ä¸ä¸å·¦å³ãæåã«æ¢ç´¢ãããã¨ã«ãã¾ãããã¹ã³ã¢ã8%ã»ã©è¯ããªãã¾ãããseed99ã®ãã¸ã¥ã¢ã©ã¤ã¶ãè¦ã¦ãä¸èªç¶ãªåãã¯ãªããªã£ãããã§ãã
絶対ã¹ã³ã¢ã1000ãããå°ãªããªãã¾ãããããï¼
ããããããªããé ä½è¡¨ãè¦ã¾ããç¸å¯¾ã¹ã³ã¢ã¯14,220,973,384ã«ãªããé ä½ã¯128ä½ã«ãªãã¾ãããçµæ§ä¸ãã£ãï¼ããããã
ï¼ã¿ã¼ã³ç®ã¯ä¸ã§ã¯ãªãä¸ã«è¡ã£ã¦ã»ãããä¸çªå¤æ°ãè¡ãããæ¹åãé¸ã¶ããã«ãã¾ãã
1ã¿ã¼ã³ç®ã¯å¥ã®ã¨ããããã¹ã¿ã¼ãããããã«ãªãã¾ãããã¹ã³ã¢ã¯268ã«ãªããã ãã¶è¯ããªã£ã¦ãã¾ãã100ãã¹ãã±ã¼ã¹ã試ãå§ãã¦æ°ã±ã¼ã¹è¦ã¦å ¨ã¦è¯ããªã£ã¦ãããã ã£ãã®ã§ãã¹ãã±ã¼ã¹ãçµããã®ãå¾ ã¡ãããã«æåºããã¾ãã
絶対ã¹ã³ã¢ã¯10220ã§ãããããããã§1ä¸ãåããï¼
ç¸å¯¾ã¹ã³ã¢ãä¸ããã¾ããï¼ãã£ããï¼
ç¡é§ãªæ¢ç´¢ãåã£ãã®ã§ã試è¡åæ°ãå¹³å800åãããã«ãªãã以åã®5åã»ã©ã«ãªãã¾ããã
15.ã³ã³ãã¹ã9æ¥ç®ï¼åæ解ã®èã®é·ãã®èå¯ï¼
2024å¹´10æ12æ¥åææ¥ã®åå¾ã§ããä»é±ã¯ãã£ã¨ä½èª¿ããããã¾ãããç±ã¯ãªãã®ã§ããåãçãã¦ä»ã声ãåºã¾ãããå ã»ã©ç é¢ã«è¡ã£ã¦è¬ãããã£ã¦ãã¾ãããè¬ã飲ãã§å°ãå¯ã¦ããã£ã¨æ¥½ã«ãªã£ã¦ããã¨ããã§ãã
æ®ã3æ¥ã§ãããããã¨ã§ãã
- åãé·ãã2ã¤æã¡ã決ã¾ã£ãã«ã¼ããå·¡åãã180度å転ãè¡ã解æ³ã試ã
- æ ¹ã®ä¸ä¸å·¦å³ã®ç§»åå¾ã«è²ªæ¬²ãã¬ã¤ã¢ã¦ããè¡ã£ã¦ãã¡ã°ãããã£ãè¡åãé¸ã¶è§£æ³ã試ã
- ã§ãããã£ã解ã®ã«ã¼ããå¤ãã解æ³ã試ã
ä¸çªä¸ã¯æ¸ãã¦ã¿ããã©éä¸ã§ãã°ã£ãã®ã§ä¸æ¦ä¸æ¢ã
ããããã°ãå±±ç»ãå¾ã®æçµçãªãã¹ãã¹ã³ã¢æã®èã®é·ããã©ããªã£ã¦ãããã調ã¹ããã¨ã«ãã¾ãã
èã®é·ãã¯å ¨ä½çã«é·ããªã£ã¦ããããã«æãã¾ãããç¹ã«Vãå°ããã¨ãã«é¡èã
試è¡åæ°ã足ãã¦ããªãããã§ãåæ解ã®å½±é¿ãå¼·ãåããããã§ãã
16.ã³ã³ãã¹ã10æ¥ç®ï¼æ ¹ã®ç§»åã«ã¤ãã¦ã®èå¯ï¼
2024å¹´10æ13æ¥æ¥ææ¥ã®æã§ããã³ã³ãã¹ãæ®ã2æ¥ã¨ãªãã¾ããã
å³ã®ã»ããã¹ã³ã¢ãè¯ããªãã¾ãã20æç®ã§ã¯æãããªå·®ãã¤ãã¦ãã¾ããä¸çªå·¦ã®ãã®ã¯æ ¹ã®ç§»åã§ãéãå·¦ã赤ãå³ã«ãªãã¾ããããã¯ã«ãªã£ã¦ããã®ã¯ããã(0,5)ã«ããããç¼ããå·¦ã§ã¯æå¾ã¾ã§æ®ãã¦ãã¾ã£ã¦ãã¾ãããå³ã§ã¯12æç®ã«åã£ã¦ãã¾ãã
éå½ã®åããéã¯ä¸çªå·¦ä¸ã®(14,2)ã«ããç¼ããç½®ããå·¦ã®8æç®ã ã¨æãã®ã§ãããåãä½ç½®åãã§ãå³ã¯ã¾ã 4æç®ã§ãã
éä¸ã«å ¥ãè¾¼ããªããã¨ãããã¨ãèãã¦ãã¾ããããããã¯åãé çªãæ示ããªãåããªããããªå ´æã§ããã¾ãæ ¹ã®ãã¸ã·ã§ã³ã¯ä¸å¤®å¯ãã®æ¹ã好ã¾ããã¨ããå ç¹ã¯ãã¦ãè¯ãããã«æãã¾ããã
ãããã¸ã¥ã¢ã©ã¤ã¶ãè¦ãªãããµã¨æãã¾ãããä½ã§ãããªåãããã¦ããã®ã ããã¨ã
ãããèããã¨ãèã¯ãã¹ã®å¤ã«ãããããã¨ãèæ ®ãã¦ãã¾ããã§ããã
ããç¹ã«åé¡ãªãããã
- æ ¹ã¯ä¸å¤®ã«ããã®ãè¯ããèã¯å¤å¨ã«ããã®ãè¯ãã
ä½ãä»ããå½ããåãªã®ããããã¾ããããããªãã¨ã«æ°ãã¤ãã¾ããã
ããã¯æããã®ã®ä½ãã§ããã
åæã®æ ¹ã®åº§æ¨ã¨æ¢ç´¢æ¹æ³ã®æ¹åããã«ããã«ãã¨ãã£ã¦ãã¾ãããå°ãã ãæ¹åã
Â
ãã¼ããããããã¨ãã£ã¦ã¿ããã©ãã¾ããããªãã
ä½ãã¨ããã¨å¥¥ããè©°ãã¦ããã¿ãããªã®ã
é²æãªããå¯ã¾ãã
17.ã³ã³ãã¹ãæçµæ¥
2024å¹´10æ14æ¥æææ¥ã®æã§ããä»æ¥ã¯ç¥æ¥ãªã®ã§ãä¼ã¿ã§ãã
æ¨æ¥ã¯ä¸æ¥é²æããªããæ®å¿µãªæ¥ã§ããã
èªåã®ã³ã¼ãã§æã£ã¦ããã®ã¨éãæåã¯ããã£ã¦ãã¦ãæãæ¹åã«ããç¼ããç½®ãã¦ãããã¨ã§ãã
ä¸æãã¤é ã«è¦ãã¨ç§»åã90度ã ããããªãã¨ããæ°æã¡ã«ãæåãã180度å転ã«ãã¦ãããæ¹ããå¾ãªã®ã«ãªãã
ã³ã¼ããè¦ç´ãã¾ãã
ããããããã¦ç´ã£ãï¼ï¼å·¦ç«¯ãï¼åæ®ã£ã¦ããã®ãæ°ã«ãªããã©ï¼æ¢ç´¢ã®åªå 度ã§ç¾ç¶ãå ¥ããã®ãå¿ãã¦ãã¾ãããï¼ä¸æå ã®ãã®ããèæ ®ãã¦ããªãã£ãï¼
ã¨ããã§ãèã®é·ãã®èå¯ããä¸æ©çµã£ããæèãã¾ã¨ã¾ã£ãã®ã§å³ã«ãã¦ã¿ã¾ãããå·¦å³ãå ¥ãæ¿ããã®ã«è¯ããããªèã®é·ãã§ãã
- (0.5N+V)/2ãèã®é·ãã®æ大ã¨ãã
ææ©ãèµ·ãããã¦ãã¾ã£ãã®ã§äºåº¦å¯ããã¦ãã¾ãããé ä½è¡¨ãæèµ·ããã¨è¦ãã®ã§ãããã ãã¶é ä½ãä¸ãã£ã¦ãã¦æ²ãããä»ã¯1035人ä¸174ä½ã§ããä»åã2æ¡é ä½ã¯ãã¡ã ã£ãããªãéããã©ã¯ãªãã¨ãç¶æã§ããããªãããã§ããé ä½è¡¨ã®ãããã§ã¯ Topcoderã®Marathon Match ã§ããªãã¿ã®wleiteããã2ä½ã«ãªã£ã¦ãã¾ããï¼
18.ãçµããã«ãããã®æªããã
ãããããã¨3æéã»ã©ã§ã³ã³ãã¹ããçµããã¾ããéä¸ã¯èª¿åãããã£ãã®ã«æå¾ã¯ãã¾ããããªããªãã¨æã£ãã¾ã¾çµãããè¿ãããã¨ã«ãªãã¾ãããä»ã¯ããã¾ã§ã®æåºã§1000ãã¹ãã±ã¼ã¹ã試ãã¦ããã¨ããã§ããç¹ã«åé¡ããªããã°ãããæçµæåºã«ãããã¨æãã¾ãã
ä¸çªè¯ãã£ãã®ã¯seed0ã®ã¹ã³ã¢31ã§ããã
ããçµããã«ããããã¨æã£ãã®ã§ãããåºåããã¹ã以ä¸ã®é·ãã«ãªã£ãæç¹ã§ã®æã¡åããå ¥ãã¦ãã¾ããã§ããã100ãã¹ãã±ã¼ã¹ã試ãã¨å°ãè¯ããªã£ã¦ããã®ã§æåºããã¾ãããã絶対ã¹ã³ã¢ãç¸å¯¾ã¹ã³ã¢ãå°ãä¸ããã¾ããã
ã¾ãã100ãã¹ãã±ã¼ã¹ã®ã¹ã³ã¢ãè¦ã¦ããããæã¡åããå ¥ãã¦ãå¤ãããªããã®ãããã¾ããã試è¡åæ°ã1ä¸å以ä¸ãããã®ã«é¢ãã¦ã¯ãã¹ã¿ã¼ãå°ç¹ãå®å ¨ãªã©ã³ãã ã«å¤æ´ãã¾ããï¼ç¾å¨ã¯ããç¼ããããã¨ããããã¹ã¿ã¼ããã¦ããï¼ãè¯ããªããã®ã¨æªããªããã®ãããã¾ããããå¾åã¨ãã¦ã¯è¯ããªã£ã¦ãããã§ãã30åå¾ ã£ã¦ããä¸åº¦æåºããã¾ãã
18.çµããã«
ããã¦ãä»åº¦ããæ¬å½ã«ã³ã³ãã¹ããçµäºãã¾ããæçµæ¥ã«å°ãæ¹åãã§ãã¦ãæããã£ãæ°æã¡ãå°ãã ãè½ã¡çãã¾ããããã£ã¨ããã解æ³ãæãã¤ãããã£ãã¨æããã®ã®ã11æ¥éããããèãããã¨ãã§ããã®ã§ãã¨ã¦ã楽ããæéãéãããã¨ãã§ãã¾ããã
次ããã¯ãã£ã¨ä¸ä½ã«ããããï¼
ãã¦ãã³ã³ãã¹ããçµäºããå¾ã¯ãXã®ãã¹ããææ³ä¼ã¹ãã¼ã¹ãAHCã©ã¸ãªãªã©ã§ä»ã®äººã®è§£æ³ãèããããèªåã®è§£æ³ãæ¯ãè¿ããã¨ã®ã§ããæéãå¾ ã£ã¦ãã¾ããã¨ã¦ã楽ãã¿ãªæéã§ããã¨åæã«ããã£ããã¨èªåã®ç³§ã«ãã¦æ¬¡ã«é²ã¿ããã¨æãã¾ããããã§ã³ã³ãã¹ãã®åå è¨ã¯çµäºã§ããé·ãæç« ãããã¾ã§èªãã§ãã ãããããã¨ããããã¾ããããã²ã¾ã次åã®ã³ã³ãã¹ãã§ãä¼ããã¾ããããä¸ç·ã«ç«¶ãåããã®ã楽ãã¿ã«ãã¦ãã¾ãã
19.æçµçµæï¼2024å¹´10æ16æ¥æ´æ°ï¼
ã·ã¹ãã ãã¹ãã®çµæã§ãã2000ãã¹ãã±ã¼ã¹ã§å ¨ã¦ACãã¦ãã¾ããã2900msã«ãªãããæé管çããã¦ããã®ã§ãå®è¡æéã®çµæããã®ã¾ã¾ã§ããã
é ä½ã¯æ«å®æã®194ä½ããå°ãä¸ããã1088人ä¸190ä½ã«ãªãã¾ããã6ä½ã®wleiteãããä½ã£ã¦ãã ãã£ãã·ã¹ãã ãã¹ãã®çµ±è¨è¡¨ãå¼ç¨ããã¦ããã¤ãã¨ã«ãã¾ãã   äºæ³éãã§ãããVãå°ããã¨ãã®é ä½ãããã£ãã§ãã
çµ±è¨è¡¨ã¯ãã¡ãããâ
AtCoder #AHC038 statisticshttps://t.co/fM6xn5Lxdk
â Wladimir Leite (@wleite) 2024å¹´10æ15æ¥
Scores are normalized to 100.
çµæã¨ãã¦ã¯éå»4çªç®ã«é«ã1717ã¨ããããã©ã¼ãã³ã¹ãåºããã¨ãã§ãã¾ããã
ã¨ã¯ãããã®ã®ãä»ã®æ¹ã®è§£æ³ãææ³ä¼ã¹ãã¼ã¹ã§ã®è©±ãèãã¨ãèªåã®èå¯ãã¾ã ã¾ã ã ãªãã¨åçããæ°æã¡ãããããã£ã¦ããã¨ããã§ãã
ææ¥2024å¹´10æ17æ¥ã®å¤20æããã¯AHCã©ã¸ãªãããã®ã§ãã£ãã復ç¿ã«åãçµã¿ããã¨æãã¾ãã
ãã¥ã¼ãªã¹ãã£ãã¯ã®Ratingã¯19ä¸ãã1701ã«ãªãã¾ããããã1å¹´éã§100ãããä¸ãã£ã¦ããã®ã§ããã¨3å¹´ã§é»è²ã«ãããããããªãã¨æãã¾ãã