杭电ACM 2043 密码


http://acm.hdu.edu.cn/showproblem.php?pid=2043


#include 
using namespace std;

int main()
{
	char ch[50];
	int M;
	bool flag1,flag2,flag3,flag4;
	cin>>M;
	while(M--){
		cin>>ch;
		flag1=0;
		flag2=0;
		flag3=0;
		flag4=0;
		int len=strlen(ch);
		if(len>16||len<8){
			 cout<<"NO"<='A'&&ch[i]<='Z') flag1=1;
			else if(ch[i]>='a'&&ch[i]<='z') flag2=1;
			else if(ch[i]>='0'&&ch[i]<='9') flag3=1;
			else  flag4=1;  //if(ch[i]=='~'||ch[i]=='!'||ch[i]=='@'||ch[i]=='#'||ch[i]='$'||ch[i]=='%'||ch[i]=='^')
		}
		/*
cout<<"\t"<=3)  cout<<"YES"<


你可能感兴趣的:(hdu)