Online JudgeProblem SetAuthorsOnline ContestsUser
Web Board
Home Page
F.A.Qs
Statistical Charts
Problems
Submit Problem
Online Status
Prob.ID:
Register
Update your info
Authors ranklist
Current Contest
Past Contests
Scheduled Contests
Award Contest
User ID:
Password:
  Register

快晕死了!!!倒底哪不行了!

Posted by afc163 at 2006-03-26 15:27:57 on Problem 1936
//acm 1936
//All in All
#include <iostream>
using namespace std;
#include <string>

int main()
{
	string s , t;
	cin>>s>>t;
	while(cin)
	{
		int number = 0;
		int k=0;
		for(int j=0;j<s.size();j++)
		{
			for(;k<t.size();k++)
			{
				if(s.at(j)==t.at(k))
				{
					number++;
					break;
				}
			}
		}
		if(number == s.size() && s.size() <= t.size())
			cout<<"Yes"<<endl;
		else
			cout<<"No"<<endl;
		cin>>s>>t;
	}
		return 0;
}

Followed by:

Post your reply here:
User ID:
Password:
Title:

Content:

Home Page   Go Back  To top


All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator