mirror of
https://github.com/Kiritow/OJ-Problems-Source.git
synced 2024-03-22 13:11:29 +08:00
1c7c39b791
4200-4299
31 lines
615 B
C++
31 lines
615 B
C++
#include<iostream>
|
|
#include<string.h>
|
|
#include<string>
|
|
using namespace std;
|
|
int main()
|
|
{
|
|
char str[100];
|
|
int a[200];
|
|
while(gets(str) != NULL)
|
|
{
|
|
if(strcmp(str, "END") == 0)
|
|
break;
|
|
int l=strlen(str);
|
|
int i;
|
|
memset(a, 0, sizeof(a));
|
|
for( i=0; i < l; i++ )
|
|
{
|
|
if(str[i] >= 'A' && str[i] <= 'Z')
|
|
a[str[i]]++;
|
|
}
|
|
for( i='A'; i <= 'Z'; i++ )
|
|
{
|
|
if(a[i] > 1)
|
|
break;
|
|
}
|
|
if(i > 'Z')
|
|
puts(str);
|
|
}
|
|
return 0;
|
|
}
|