
栈
HPU2_2
这个作者很懒,什么都没留下…
展开
-
括号配对问题
描述 现在,有一行括号序列,请你检查这行括号是否配对。 输入 第一行输入一个数N(0 < N <= 100),表示有N组测试数据。后面的N行输入多组输入数据,每组输入数据都是一个字符串S(S的长度小于10000,且S不是空串),测试数据组数少于5组。数据保证S中只含有”[“, “]”, “(“, “)” 四种字符 输出 每组输入数据的输出占一行,如果该字符串中所含的括号是配对...原创 2018-03-24 09:40:31 · 166 阅读 · 0 评论 -
Binary String Matching
描述 Given two strings A and B, whose alphabet consist only ‘0’ and ‘1’. Your task is only to tell how many times does A appear as a substring of B? For example, the text string B is ‘1001110110’ while...原创 2018-04-02 17:48:42 · 103 阅读 · 0 评论 -
Train Problem I HDU - 1022
As the new term comes, the Ignatius Train Station is very busy nowadays. A lot of student want to get back to school by train(because the trains in the Ignatius Train Station is the fastest all over t...原创 2018-04-30 23:56:17 · 120 阅读 · 0 评论