水题

#include<cstdio>
#include<string.h>
#include<ctype.h>
#include<algorithm>
using namespace std;
bool jud(char a){
if(isdigit(a)||islower(a)||isupper(a)||a=='.')return true;
else return false;
}
void judge(char *arr){
int len=strlen(arr);
if(len<6){
printf("Your password is tai duan le.\n");
return;
}
int ying=0,dig=0,dot=0;
for(int i=0;i<len;i++){
if(jud(arr[i])==false){
printf("Your password is tai luan le.\n");return;
}
if(isdigit(arr[i])) dig++;
if(islower(arr[i])||isupper(arr[i])) ying++;
}
if(ying==0) printf("Your password needs zi mu.\n");
else if(dig==0) printf("Your password needs shu zi.\n");
else printf("Your password is wan mei.\n");
}
int main(){
int N;scanf("%d",&N);
getchar();
for(int i=0;i<N;i++){
char temp[100];
scanf("%[^\n]",temp);
judge(temp);
getchar();
}
return 0;
}

最新文章

  1. Python-S13-day2-之购物车
  2. [转] linux中常用的命令
  3. git生成SSH key
  4. [Leetcode][Python]27: Remove Element
  5. MySQL存储引擎中的MyISAM和InnoDB区别
  6. 什么是GUID?
  7. LINUX 笔记-mv命令
  8. 微信公众号开发C#系列-10、长链接转短链接
  9. 生成ISO文件
  10. [精品书单]3D打印机课程设计
  11. VMware修改为静态ip
  12. CAN报文 Intel 格式与Motorola 格式的区别
  13. 如何查看卖家ID (Merchant ID) 亚马逊哪里找?
  14. fedora 28 安装 wine 运行 uTorrent 解决linux 端,pt 资源下载问题
  15. Android LayoutInflater 相关知识
  16. 《Netty权威指南》(二)NIO 入门
  17. (转)mybatis-plus入门
  18. X-Forwarded-For 会少记录一次代理服务器的IP
  19. C# winfrom ComboBox 调整下拉菜单的高度
  20. mysql备份的 三种方式【转】

热门文章

  1. Android Studio中设置一个按钮的不同点击触发事件
  2. Xcode 8.X Command Line Tools
  3. Spring Cloud Hystrix——熔断器
  4. git reset命令使用
  5. 讲解ontouchstart、ontouchend、onclick区别和坑点
  6. 利用channel在goroutins之间控制同步和传递数据
  7. rtf格式 C#设置字间距 CharacterSpacing
  8. 3张表实现RBAC
  9. Java基础系列--ArrayList集合
  10. PXE | 开关机