2011-10-03から1日間の記事一覧
RequiredSubstrings動的計画法。それぞれの位置で各文字列の一致長ごとに条件を満たす文字列の個数を覚えておく。計算量が507くらいになりそうだけど、実際はそんなに大きくならないらしい。 #include <string> #include <vector> #include <map> using namespace std; vector<string> wor</string></map></vector></string>…
RequiredSubstrings動的計画法。それぞれの位置で各文字列の一致長ごとに条件を満たす文字列の個数を覚えておく。計算量が507くらいになりそうだけど、実際はそんなに大きくならないらしい。 #include <string> #include <vector> #include <map> using namespace std; vector<string> wor</string></map></vector></string>…