Skip to content

Commit 20367a2

Browse files
A - Anton and Letters
1 parent c26e5a4 commit 20367a2

File tree

1 file changed

+31
-0
lines changed

1 file changed

+31
-0
lines changed

A - Anton and Letters.cpp

+31
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
/*
2+
yildiz
3+
*/
4+
#include <iostream>
5+
#include <string>
6+
#include<iomanip>
7+
#include <algorithm>
8+
#include <vector>
9+
using namespace std;
10+
11+
int main()
12+
{
13+
int c = 0;
14+
string s;
15+
getline(cin, s);
16+
int n = s.length();
17+
for (int i = 1; i < n - 1; i++) {
18+
for (int j = i + 1; j < n - 1; j++) {
19+
if (s[j] == s[i]) {
20+
s[i] = ' ';
21+
}
22+
}
23+
}
24+
for (int i = 0; i < n; i++) {
25+
if (s[i] >= 97 && s[i] <= 122) {
26+
c++;
27+
}
28+
}
29+
cout << c;
30+
return 0;
31+
}

0 commit comments

Comments
 (0)