unit Unit2;

interface

uses
  Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
  Dialogs, StdCtrls;

type
  TForm2 = class(TForm)
    Label1: TLabel;
    procedure FormActivate(Sender: TObject);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  Form2: TForm2;

implementation

uses Unit1;

{$R *.dfm}

procedure TForm2.FormActivate(Sender: TObject);
begin
 Label1.Caption:='Średnia='+FloatToStrF((Form1.e1+Form1.e2+Form1.e3)/3,ffFixed,8,2)+#13+
 'Suma kwadratów='+IntToStr(Form1.suma_kwadratow); //funkcja zdefiniowana w module Unit1

end;

end.
