POJ-1936-All in All

题目:POJ-1936-All in All

水题。

 1 #include <iostream>
 2 #include<stdio.h>
 3 #include<stdlib.h>
 4 #include<string.h>
 5 #include<math.h>
 6 #include<algorithm>
 7 
 8 using namespace std;
 9 
10 char s[100010],t[100010];
11 
12 int main()
13 {
14     int i,j;
15     while(scanf("%s%s",s,t)!=EOF)
16     {
17         i=0;
18         for(j=0;j<strlen(t);j++)
19         {
20             if(s[i]==t[j]) ++i;
21         }
22         if(i==strlen(s)) printf("Yes\n");
23         else printf("No\n");
24     }
25     return 0;
26 }

 

posted @ 2015-02-09 09:42  alohagin  阅读(107)  评论(0编辑  收藏  举报