2371专题

hdoj 2371 decoded string. Decode the Strings

http://acm.hdu.edu.cn/showproblem.php?pid=2371 题意:给出编码的原则,给一个字符串,输出该字符串经过m次解码后的字符串。 啊啊啊啊。。。。无耻的看错题意了,以为给出字符串输出经过m次解码的后的字符串,样例死活过不了,赛后才发现问的是“decoded string”. 即解码后的字符串。。 思路:对于 5 3 2 3 1 5 4 helol

POJ 2371排序水题

题意:将数组从小到大排序,输出指定位置的值; #include<iostream>#include<algorithm>int a[100010];using namespace std;int main(){int n,m,i,j;char c[5];cin>>n;for(i=0;i<n;i++)cin>>a[i];sort(a,a+n);cin>>c;cin>>m;while(m-