Skip to content
This repository has been archived by the owner on Jan 6, 2025. It is now read-only.

Commit

Permalink
3.0 final build
Browse files Browse the repository at this point in the history
  • Loading branch information
pikalovguessfor committed Jul 18, 2024
1 parent c8c27a5 commit 2f296f6
Show file tree
Hide file tree
Showing 12 changed files with 57 additions and 22 deletions.
1 change: 1 addition & 0 deletions DataBase/DataBase.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,7 @@
<ClInclude Include="defs.h" />
<ClInclude Include="includes.h" />
<ClInclude Include="name_gen.h" />
<ClInclude Include="parcer.h" />
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
Expand Down
3 changes: 3 additions & 0 deletions DataBase/DataBase.vcxproj.filters
Original file line number Diff line number Diff line change
Expand Up @@ -29,5 +29,8 @@
<ClInclude Include="name_gen.h">
<Filter>Frameworks</Filter>
</ClInclude>
<ClInclude Include="parcer.h">
<Filter>Frameworks</Filter>
</ClInclude>
</ItemGroup>
</Project>
1 change: 0 additions & 1 deletion DataBase/Page/1151.txt

This file was deleted.

1 change: 0 additions & 1 deletion DataBase/Page/13021un.txt

This file was deleted.

1 change: 0 additions & 1 deletion DataBase/Page/26739_un.txt

This file was deleted.

Empty file removed DataBase/Page/31503_un.txt
Empty file.
Empty file removed DataBase/Page/3376_un.txt
Empty file.
1 change: 0 additions & 1 deletion DataBase/Page/3438_un.txt

This file was deleted.

9 changes: 2 additions & 7 deletions DataBase/Source.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -228,6 +228,7 @@ int main() {
else if (SlineRd.Command == ComArray[1]) { // algorithm to find a symbols in file
ioClass insideFind;
TextWork TextInsideFind;
Parcer ParceSpec;

string nameFileF = "Page/";
string nameFileS;
Expand All @@ -243,20 +244,14 @@ int main() {
if (fileToRead.is_open()) {

TextInsideFind.Text;
long count = 0;

cout << endl << "file is open" << endl;
for (int i = 0; i <= 1999; i++) {
fileToRead.get(TextInsideFind.SymArr[i]);
}

ParceSpec.ParseFile(TextInsideFind.SymArr);


cout << endl << endl << endl;
cout << "Numbers of special symbols inside your file is -> " << count;
cout << endl << endl << endl;


fileToRead.close();
}
else {
Expand Down
11 changes: 0 additions & 11 deletions DataBase/defs.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,14 +25,3 @@ void Get_Exit() {// function to abort programm
exit(0);
}

int ParseFile(char arrSym[2000]) {

bool operation_stop = false;




if (operation_stop) {
return 0;
}
}
1 change: 1 addition & 0 deletions DataBase/includes.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@

#include "defs.h"
#include "name_gen.h"
#include "parcer.h"

#include <conio.h> // windows depended lobrary
#include <filesystem> // windows depended library
50 changes: 50 additions & 0 deletions DataBase/parcer.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
#pragma once

#include "includes.h"

class Parcer {

public:

const char arrSymbolsSpec[5] = { '#', '@', '&', '-', '>' };

int ParseFile(char arrSym[2000]) {

bool operation_stop = false;


if (true) {

for (int i = 0; i <= 1999; i++) {

if (arrSym[i] == arrSymbolsSpec[0] or arrSym[i] == arrSymbolsSpec[1] or arrSym[i] == arrSymbolsSpec[2] or arrSym[i] == arrSymbolsSpec[3] or arrSym[i] == arrSymbolsSpec[4]) {

cout << endl << arrSym[i - 10] << arrSym[ i - 9] << arrSym[i - 8] << arrSym[i - 7] << arrSym[i - 6] << arrSym [i - 5] << arrSym[i - 4] << arrSym[i - 3] << arrSym[i - 2] << arrSym[i - 1] << arrSym[i] << endl;

}
}
}

return 0;

}

private:

bool _findSymTxt(char arrSym[2000]) {

for (int i = 0; i <= 1999; i++) {

if (arrSym[i] == arrSymbolsSpec[i]) {
return true;
}

else {
return false;
}

}

}

};

0 comments on commit 2f296f6

Please sign in to comment.