zoukankan      html  css  js  c++  java
  • 字符串匹配

          对于两个字符串之间的匹配:

    二分匹配实在看不懂,我自己的办法是设两个数组,用于标记字符串中'a'-'z'的个数,然后比较两个数组时候一致,一致则匹配

    TOJ 1856.   Anagrammatic Distance 

    统计两个字符串中字符的差异数

    Code

    TOJ 2468.   Counting Letters

     统计字符串中各字符的数量

    Code

    TOJ 2943.   Love Letter

    此题极度纠结,输入麻烦,匹配也麻烦,写了半天仍然WA

    后来Roba大牛告诉我“这个程序很怪,我把它拿到TOJ上去测,结果都是对的。不知道为什么交上去就是WA... ”

    Code

    TOJ 2628.   Subsequence

    简单的字符串匹配,子序列 

    Code

    TOJ 1911.   Easier Done than Said?

    简单地统计字符数,判断单词是否符合语法规则

    Code

     

  • 相关阅读:
    Codeforces Round #343 (Div. 2) B. Far Relative’s Problem 暴力
    Codeforces Round #343 (Div. 2) A. Far Relative’s Birthday Cake 水题
    Educational Codeforces Round 8 F. Bear and Fair Set 最大流
    Educational Codeforces Round 8 E. Zbazi in Zeydabad 树状数组
    Educational Codeforces Round 8 D. Magic Numbers 数位DP
    Educational Codeforces Round 8 C. Bear and String Distance 贪心
    Educational Codeforces Round 8 B. New Skateboard 暴力
    Educational Codeforces Round 8 A. Tennis Tournament 暴力
    BZOJ 4032: [HEOI2015]最短不公共子串 后缀自动机 暴力
    BZOJ 4031: [HEOI2015]小Z的房间 高斯消元 MartixTree定理 辗转相除法
  • 原文地址:https://www.cnblogs.com/ftyblog/p/1413238.html
Copyright © 2011-2022 走看看