2016-01-01ãã1å¹´éã®è¨äºä¸è¦§
Qiitaã¨Adventarã«ããã¢ããã³ãã«ã¬ã³ãã¼ã«ã¤ãã¦ãåå¥ã®è¨äºã¨ã«ã¬ã³ãã¼å ¨ä½ã®ã¯ã¦ãªããã¯ãã¼ã¯æ°ã®ã©ã³ãã³ã°ã27æ¥ã®0æããã«éè¨ãã åå¥è¨äºä¸ä½100件ã®URLã«ã¤ãã¦ã¯è»½ãç®ã§è¦ã¦æè¿ã®è¨äºã§ãªãã£ããããURLããã£ã«ã¿ãªã³ã°ãã¦ãã(æ¼ãâ¦
æ¥ä»ã表ãæ¸å¼æååã®ä¸ã¤ã«%Gã¨ãããã®ãããã¾ã(æå³ããã¨ããã¯ãã¼ã«ãé¢æ°ã«ãã£ã¦éãããããã¾ãã) PHPã®æ¥æ¬èªããã¥ã¡ã³ãã¨ããã³ãã¬ã¼ãã¨ã³ã¸ã³ã®Smartyã®ããã¥ã¡ã³ãããããã¥ããã¦ã西æ¦ã®4æ¡ã®å¹´ã表示ãã%Yã¨ééãã¦%Gã使ã£ã¦â¦
å»å¹´æ¸ããã¹ã¯ãªããâãã ããããã®ã¾ã¾åããã®ã§ã¢ããã³ãã«ã¬ã³ãã¼ã®ã¯ã¦ãªããã¯ãã¼ã¯ã®åè¨æ°ã®ã©ã³ãã³ã°ã¨è¨äºå¥ã®ã©ã³ãã³ã°ãä»å¹´ãåºãã¦ã¿ã sucrose.hatenablog.com å ¨ä»¶è¨äºãè¦ãããã§ã¯ãªãã®ã§å¤ãªã´ããæ··ãã£ã¦ããããä»å¹´ã¯ãã£ã¼â¦
ã½ã·ã£ã²ããã£ã¦ãã¦ãããã確çãªã©ã調ã¹ãã«ã¯ä½åããã試ãã°ãããããæ°ã«ãªã£ãã®ã§èª¿ã¹ã¦ã¿ãä¸å®ç¢ºç\(p\)ã§æåã\(1-p\)ã§å¤±æããã¨ããåç´ãªã¢ãã«ãä»®å®ãã ã¤ã¾ããã確ç\(p\)ã§ã¢ã¤ãã ãããããããã¨ããã¨ãã«ã試è¡åæ°ã«å¯¾ããâ¦
ã·ã§ã«ã¹ã¯ãªããã®ifæã§æååã®è¾æ¸é ã®å¤§å°é¢ä¿ãæ¡ä»¶å¤å®ãããã£ãã®ã§èª¿ã¹ã¾ããbashãªã©ã«ã¯[[]]ã³ãã³ããããã®ã§ãç°¡åã«æååæ¯è¼ãã§ãã¾ã(ã¨ããã§[[]]ã£ã¦æ¤ç´¢ãã¥ããã§ãã[](test)ã³ãã³ãã®æ¹ã§ãæååã®å¤§å°æ¯è¼ã¯ã§ãã¾ããã以ä¸ã®â¦
å»å¹´Advent Calendarã®åå è ã1å¹´éã§ã©ããããå ¥ãæ¿ãã£ã¦ããã®ã調ã¹ã¾ãã sucrose.hatenablog.com ãã£ãããªã®ã§ä»å¹´ã調ã¹ã¦ã¿ã¾ã2016å¹´ã¨2015å¹´ã®Qiitaã§å ¬éããã¦ããã¢ããã³ãã«ã¬ã³ãã¼ã調æ»ã®å¯¾è±¡ã¨ãã¾ã Advent Calendar 2016 - Qiita â¦
確çã®è©±ã¨ãã¯åºãã«ç´ç²ã«å ´åã®æ°ã®è©± ä¸è¯æçåºãªã©ã«ãããããªå転ãããã¼ãã«ãè±èªã§"Lazy Susan"ã¨å¼ã°ããã¨ããããªãã¢ãåãä¸ãããã¦ãã(ããå¿ãããå ´åã®æ°ã¯ããèããªãã¨ãããã«ééããã®ã§é£ãã åãä¸ãã¦ãå 容ã¯ä»¥ä¸ã®ãããªâ¦
Chromeã«å ¥ããæ¡å¼µæ©è½(ã¨ã¯ã¹ãã³ã·ã§ã³)ã¯èªåçã«æ´æ°ããã¦ãã¾ã èªåæ´æ°ãåæ¢ãã¦ãã¼ã¸ã§ã³ãåºå®ãã¦ä½¿ãæ¹æ³ã¯ãªãããªãã¨è»½ã調ã¹ã¦ã¿ããããæ¹æ³ãè¦ã¤ãããªãã£ãã¡ã¢ çµç·¯ ãã®åè¨äºã«æ¸ãããã©Chromeæ¡å¼µããããã¼ã¸ã§ã³ã«ã¢ãããã¼â¦
æè¿Chromeæ¡å¼µãçªç¶æªè³ªåãã¦ãã«ã¦ã§ã¢ã«ãªãæ å ±ãçãã ãããäºä¾ãããã¨ãã話ã話é¡ã«ãªã£ã¦ãã¾ããä»æ¥Chromeãèµ·åããããä¸æ£ãªChromeæ¡å¼µãç¡å¹ã«ãã¾ãããçãªãã¨ãè¨ããã¦Chromeæ¡å¼µãç¡å¹åããã¦ãã¾ãã¾ãã ãããæªè³ªãªãã¨ã«ã¢ã³â¦
ç´æ°ã®åæ°ãæ±ããã¢ã«ã´ãªãºã ã¨ç´æ°ãå¤ãæ°ã§ããé«åº¦åææ°ã«ã¤ãã¦ã®ã¡ã¢ ç´æ°ã®åæ°ã®æ±ãæ¹ å®éã«å²ã£ã¦ã¿ãæ¹æ³ ããæ°\(n\)ã®ç´æ°ã®æ°ãæ±ãã¾ã \(\sqrt n\)ãã大ããç´æ°ã¯\(n\)èªèº«ãããªãã®ã§ã\(1\)ãã\(\sqrt n\)ã¾ã§å²ãã°ååã§ã å²â¦
Google Data Studio (ãã¼ã¿ã¹ã¿ã¸ãª) ã¨ããå¯è¦åãµã¼ãã¹ããã¼ã¿çã§ä½¿ããããã«ãªã£ã¦ããã®ã§è©¦ãã¦ã¿ãè¦ããæ°å¤ãä¸è¦§ããããã®ããã·ã¥ãã¼ãçãªãã®ãä½ãããã®ãµã¼ãã¹ãªã®ã§ãããããªå ´æãããã¼ã¿ãåã£ã¦ãã¦ä¸ç®æã§ã¾ã¨ãã¦ç¢ºèªããâ¦
qiita.com ä¸ã®è¨äºã§BigQueryã«æããã¯ã¨ãªã®ãã°(Audit Log)ãã¤ã³ãã¼ãã§ãããã¨ãç¥ã£ãã®ã§ãä¼ç¤¾ã§ä½¿ããã¦ããBigQueryã®ã¢ã«ã¦ã³ãã«ã¤ãã¦æ¯æ¥ã¯ã¨ãªã®èª²éé¡(å¦çãããã¤ãæ°)ã®å¤ãã¦ã¼ã¶ã¼ãSlackã«éç¥ãã¦ã¿ãã¡ãªã¿ã«Audit Logsãã¤ã³ãâ¦
2016å¹´9ææ«ã®ãªãªã¼ãºã§BigQueryã«ããããæ©è½ã追å ããã¾ãã å人çã«ä¾¿å©ããã ãªãã¨æã£ããã®ãç´¹ä»ãã¾ã Release Notes | BigQuery | Google Cloud Platform cloud.google.com æ¨æºSQL (Standard SQL) BigQueryã§ã¯ç¬èªã®SQLã使ã£ã¦ããã®ã§ããâ¦
競æããã°ã©ãã³ã°ãµã¤ãã®AtCoderã®ã¬ã¼ãã£ã³ã°ã®ä»çµã¿ãæ°ãããªãã¾ãã å¥ã®ç«¶æããã°ã©ãã³ã°ãµã¤ãã§ããCodeforcesã®ã¬ã¼ãã£ã³ã°ã¨ã©ããããç¸é¢ãããã®ããåå åæ°ãã©ããããããã°ã¬ã¼ãã£ã³ã°ã«å·®ããªããªã£ã¦ããã®ããªã©æ°ã«ãªã£ãã®â¦
ä¹ ãã¶ãã«åå¨ãæãåºããã®ã§å°ããã£ã¦ã¿ããæ¡ä»¶ãããããªã£ã¦ãã¦ç°¡åã«åãã翻訳ã»æ票ãããã®ãæ¡ç¨ãããã¨ã«ã«ããã¤ã³ããè²°ãã¦ã300ãã¤ã³ã以ä¸ã«ãªãã¨ç¿»è¨³è ããã¸ãè²°ãã(æ¢ã«300ãã¤ã³ã以ä¸ãã£ãããããæ°å¶åº¦ã«ãªã£ã¦ããåãã¦ãâ¦
ä¾ã®ãã¨ãâéå»ã®æ»ç¥ã¨åããã©ã¼ãããã§æ»ç¥ãæ¸ãã¦ããã¾ã ããã«ãã¼ã«ã®ããã²ã¼ã ãããã«ãï½ã¯ ãµãã¼ãã¨ãã¼ãããã®æ»ç¥ - å¯ç©æ¯ç @Scaled_Wurm ãããã«ãã¼ã¯ï¼ãã¾ã¼ã°ãã¼ãããã blog.hackadoll.com ã·ããªãªå¥ã®é¸æè¢ã®çµæ æ°´çã â¦
æ¦è¦ Google Chromeã使ã£ã¦ãdocument.write()ã§å¤é¨ã®JavaScriptãèªã¿è¾¼ãã§ãããã¼ã¸ãéãã¨ããã¤ã®éã«ãéçºè ãã¼ã«ã®ã³ã³ã½ã¼ã«ã«ä»¥ä¸ã®ãããªã¡ãã»ã¼ã¸ãåºãç¶æ ã«ãªã£ã¦ãã "A Parser-blocking, cross-origin script, ã¹ã¯ãªããã®URL, is iâ¦
åã«ãããªè¨äºãæ¸ãã¾ããsucrose.hatenablog.comTwitterã§è¦ãããã®ã§ããPHP 7.1ã§ç´ãäºå®ãããã§ãPHP 7.1ã§mt_rand()åé¡ãã¤ãã«è§£æ±ºãããã®ã? ä¸è²«ãã¦å£ãã¦ããmt_rand()ãç´ãã¨ãç´ æ´ãããPHP: ä¸ä½äºææ§ã®ãªãå¤æ´ç¹ - Manual https://tâ¦
æè¿Twitterã§æµè¡ã£ã¦ããæ¥æ¬èªã®èªå½å診æã®çµæã®ãã¤ã¼ãã®åå¸ãå¤ã¨ãã話ãããã¾ãã qiita.comãã¾ã«Twitterã§ã¿ãããWeblioã®è±åèªã®èªå½å診æã ã¨ã©ããªåå¸ãªã®ãæ°ã«ãªã£ãã®ã§èª¿ã¹ã¦ã¿ã¾ãã uwl.weblio.jp以ä¸ã®ãããªå½¢å¼ã®ãã¤ã¼ããâ¦
BigQueryã§ã¯ã¯ã¨ãªã®ãã³ã«å¯¾è±¡ã®ãã¼ãã«ããã«ã¹ãã£ã³ãã¾ã ã¹ãã£ã³ãããã¼ãã«ã®ãµã¤ãºã«ãã£ã¦æéãè«æ±ãããã®ã§ãã³ã¹ãã®åæ¸ã®ããã«æ¥ä»ãªã©ã®åä½ã§ãã¼ãã«ãåå²ããã®ããã¹ããã©ã¯ãã£ã¹ã¨ãã¦ç¥ããã¦ãã¾ãqiita.comãã¼ãã«ãæ¥ä»â¦
æ¥æ¬ã®æè²ã§å°é家ãçºè¨ãã¦ãããã¨ã¯ããã¼ã¿ã«ãã£ã¦ç¤ºããã客観çãªã¨ããã³ã¹ããªãã®ã§ã¯ãªããæè²ã®åéã§ãã¨ããã³ã¹ã大äºãã¨ãã話ã¢ã¡ãªã«ãªã©ã®å½ã§ã©ã³ãã åæ¯è¼è©¦é¨ãªã©ã®æ¯è¼çä¿¡é ¼æ§ã®é«ãæ¹æ³ã«ãã£ã¦å¾ãããæè²ã®ç¥è¦ãç´¹ä»ãã¦â¦
gitã§ç®¡çãã¦ãããªãã¸ããªã®ãã¡ã¤ã«ã«ééã£ã¦ãæ¹è¡ãã¿ã以å¤ã®å¤ãªå¶å¾¡æåãå ¥ã£ã¦ãããã¨ããã£ãã®ã§git grepã§ãã§ãã¯ããbashã¨ãã¯$''ã§å²ãã ä¸ã«16é²æ°ã®è¡¨è¨ãæ¸ãã¨å±éãã¦ããããããã®ã§ä»¥ä¸ã®ããã«æ¸ãã(-Iã¯ãã¤ããªãã¡ã¤ã«ä»¥å¤â¦
Chromeã«åºåãããã¯ã®æ¡å¼µã®AdBlockãå ¥ãã¦ããã¨ãWebãµã¤ãã®æ©è½ã®ä¸é¨ãåããªããã¨ãããã®ã§ã¡ã¢ã£ã¦ãã(ç°å¢ãè¨å®ã«ããã¨æã) Googleã¦ã§ããã¹ã¿ã¼ãã¼ã« æ¤ç´¢ã¢ããªãã£ã¯ã¹ã®ãã¼ã¸ããã¨ã©ã¼ãçºçãã¾ããããã°ãããã¦ããããä¸åº¦ãâ¦
Google ã® Search Console (æ§ã¦ã§ããã¹ã¿ã¼ãã¼ã«)ã§ãµã¤ããããã®ç»é²æ©è½ã£ã¦ããã¾ããã©ãã¯ã¦ãªããã°ã®å ´åã©ããªã£ã¦ããã®ããªã£ã¦ããã®ã調ã¹ã¦ã¿ãã¾ãçµè«ããããã¨Search Consoleã§ãµã¤ãããããç»é²ãããããå¿ è¦ã¯ãªããã ãªããªãrobâ¦
Pythonã§ãã¼ãããããæãæ¹æ³ã®è¨äºãæ¸ãããã¨æã£ããã©ãç´°ãã説æããã¨ããããã¨ããã©ããããã ã£ãã®ã§ã¨ããããå®éã«ãã£ã¦ã¿ãå¯è¦åã ãæ¸ãã¦ããTwitter APIã§èªåã®ãã¤ã¼ããé©å½ã«3000件ãããåã£ã¦ãã¦ãã¤ã¼ãããæå»ã¨ææ¥ãæ½â¦
åã«ãããªãã¤ã¼ãããããã¯ã½ã¨ã ãããã©ãã¼ãããã¦ããæ°ã§å®ç¾©ããããã¯ã½ã¨ã æ°â ç¡éç¿(id:sucrose)@29æç (@Scaled_Wurm) 2016å¹´4æ1æ¥ é£ä¼ã§æéããã£ãã®ã§Twitter APIã«æ £ããã¤ãã§ã«è¨ç®ãã¦ã¿ã ãã¯ã½ã¨ã ã¨ã¯ ããããããªããã©ãTwâ¦
ã¨ã¤ããªã«ãã¼ã«ä¼ç»ã§ä»æ¥4æ3æ¥ã¾ã§ãããã¬ã¤ã§ããªãã¨ã®ã㨠ã¯ãªã¢ããã¨ãããã«ãã¼ã«å 許証ãã®ç»åãããããæåã¯ãã¤ãã©ããã«ã¯ã¤ãº(ç°¡å)ã§ãããæå¾ã«ãå®æ試é¨ãã¨ãã¦2Dã·ã¥ã¼ãã£ã³ã°ã²ã¼ã ãå§ã¾ã£ã¦ç¬ãã¾ãã æå¤ã¨é£ããã®ã§ãâ¦
1.txt, 2.txt, 3.txt, ...ã®ããã«é£çªã®ãã¡ã¤ã«ããã£ãæã«ããã¡ã¤ã«åãç¹å®ã®æ¡ä»¶(ãã¨ãã°å¶æ°)ã«ãªã£ã¦ãããã®ã ããå¦çãããã¨ãããã¨ããã£ã¦ç°¡åã«èª¿ã¹ãã®ã§ã¡ã¢å¶æ°å¥æ°ã®å ´åã«ã¯æ°å¤ã®æå¾ã®æåã ããè¦ãã°å¶æ°ãå¥æ°ãã¯å¤å®ã§ããã©â¦
âã®è¨äºã«BigQueryã®äºå®ãã¦ããæ°æ©è½ãªã©ãæ¸ãã¦ãã£ãã®ã§å人çã«æ°ã«ãªã£ãã®ãç´¹ä» cloud.google.com ãã¼ãã«ã®èªåãã¼ãã£ã·ã§ãã³ã° ã¾ã ã¢ã«ãã¡çããããã©ããã¼ãã«ã®èªåãã¼ãã£ã·ã§ãã³ã°ã使ããããã«ãªãããã BigQueryã§ã¯ã¯ã¨ãªã®â¦
éçã®ãã¼ã¿ãçµ±è¨çã«è¦ã¦ããã»ã¤ãã¼ã¡ããªã¯ã¹ã®å ¥éæ¸ ã»ã¤ãã¼ã¡ããªã¯ã¹ - Wikipedia ã¢ã¦ãã«ã¦ã³ãã¨èµ°è ã®ç¶æ³å¥ã®ãã®å¾ã®å¾ç¹æå¾ å¤ãè¦ãã¨ãå¾ç¹æå¾ å¤ã¯éããã³ããããã¨ä¸ãã£ã¦ãã¾ãããå¾ç¹ç¢ºçãè¦ãã¨ç¶æ³ã«ãã£ã¦ã¯ä¸ããããããâ¦