2021-08-01ãã1ã¶æéã®è¨äºä¸è¦§
æè¿ããªãããã¾ã人æ°ãªããªãï¼ TL; DR ããªã + ã«ã¶ãã 㧠\(O(\log(n))\) æéã§å¤§å°æ¯è¼ã§ããã®ã§ãæç´ã«æ¯è¼ãã代ããã«ããã使ã£ã¦ã½ã¼ãã㦠\(O(n\log(n)^2)\) æéã§æ§ç¯ã§ããã ãããã ããªã ããªã (rolling hash) ã®ããããã軽ãâ¦