rendered paste body//--------Unit.cpp-----------------------------------------void TForm1::IvestiMasyva(const char CD[], int Mas[], int &kiek){ fd.open(CD); kiek = 0; while(!fd.eof() && kiek < MAX){ fd >> Mas[kiek]; kiek++; } fd.close();}//---unit.h//---------------------------------------------------------------------------#ifndef Unit1H#define Unit1H//---------------------------------------------------------------------------#include <Classes.hpp>#include <Controls.hpp>#include <StdCtrls.hpp>#include <Forms.hpp>//-----Papildyta----#include <fstream>#include <iomanip>using namespace std;const char CDfA[] = "masyvasA.txt";const char CDfB[] = "masyvasB.txt";const char CRf[] = "rezultatai.txt";const int MAX = 30;//---------------------------------------------------------------------------class TForm1 : public TForm{__published: // IDE-managed Components TMemo *Memo1; TMemo *Memo2; TMemo *Memo3; TLabel *Label1; TLabel *Label2; TLabel *Label3; TButton *Button1; void __fastcall Button1Click(TObject *Sender);private: // User declarations int A[MAX], B[MAX], C[MAX], n, m, k; void IvestiMasyva(const char[], int[], int&); void IsvestiABC(const char[], int[], int&, char[]); void RadimasC(); void PerskaiciavimasC(); ifstream fd; ofstream fr;public: // User declarations __fastcall TForm1(TComponent* Owner);};//---------------------------------------------------------------------------extern PACKAGE TForm1 *Form1;//---------------------------------------------------------------------------#endif