Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- #include <vector>
- #include <fstream>
- using namespace std;
- int main()
- {
- setlocale(LC_ALL, "Russian");
- ifstream origin;
- origin.open("origin.txt", ios_base::in);
- char def[]="ОЕАНИТСЛРВКУПДМЯЫЗЬГБЧЖЙХШЮЩЭЦФЪЁ";
- char deflow[]="оеанитслрвкупдмяызьгбчжйхшющэцфъё";
- char newdef[]="ОЕАНИТСЛРВКУПДМЯЫЗЬГБЧЖЙХШЮЩЭЦФЪЁ";
- int A[33];
- for(int i=0;i<33;i++){
- A[i]=0;
- }
- char r;
- while(!origin.eof()){
- origin >> r;
- for(int i=0;i<33;i++){
- if(r==deflow[i]){
- cout << r;
- A[i]++;
- }
- }
- }
- for(int i=0;i<33;i++){
- cout << i << " " << A[i] << endl;
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement