////////////////////HEADER/////////////////////////////
// stdafx.h: dołącz plik do standardowych systemowych plików dołączanych,
// lub specyficzne dla projektu pliki dołączane, które są często wykorzystywane, ale
// są rzadko zmieniane
//
#pragma once
//#pragma warning(disable:C4430)
#include "targetver.h"
#include <stdio.h>
#include <tchar.h>
void save();
Square* SInit();
Circle* CInit();
Rectangle* RInit();
class Figure
{
public:
virtual double area() = 0;
};
class Circle : public Figure
{
public:
double r;
double area();
Circle(double i);
};
class Rectangle : public Figure
{
public:
double a, b;
double area();
Rectangle(double i, double j);
};
class Square : public Figure
{
public:
double a;
double area();
Square(double i);
};
// TODO: W tym miejscu odwołaj się do dodatkowych nagłówków wymaganych przez program
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%CPP%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
double Circle::area()
{
return r * r*3.1415;
}
Circle* CInit()
{
double i;
cout << "podaj promien";
cin >> i;
Circle * pC;
pC = new Circle(i);
return pC;
}
double Rectangle::area()
{
return a * b;
}
Rectangle * RInit()
{
double i, j;
cout << "podaj wysokosc i szerokosc";
cin >> i;
cin >> j;
Rectangle * pR;
pR = new Rectangle(i, j);
return pR;
}
double Square::area()
{
return a * a;
}
Square * SInit()
{
double i;
cout << "podaj dlugosc boku";
cin >> i;
Square * pS;
pS = new Square(i);
return pS;
}
Square::Square(double i)
{
a = i;
}
Rectangle::Rectangle(double i, double j)
{
a = i;
b = j;
}
Circle::Circle(double i)
{
r = i;
}
{"html5":"htmlmixed","css":"css","javascript":"javascript","php":"php","python":"python","ruby":"ruby","lua":"text\/x-lua","bash":"text\/x-sh","go":"go","c":"text\/x-csrc","cpp":"text\/x-c++src","diff":"diff","latex":"stex","sql":"sql","xml":"xml","apl":"apl","asterisk":"asterisk","c_loadrunner":"text\/x-csrc","c_mac":"text\/x-csrc","coffeescript":"text\/x-coffeescript","csharp":"text\/x-csharp","d":"d","ecmascript":"javascript","erlang":"erlang","groovy":"text\/x-groovy","haskell":"text\/x-haskell","haxe":"text\/x-haxe","html4strict":"htmlmixed","java":"text\/x-java","java5":"text\/x-java","jquery":"javascript","mirc":"mirc","mysql":"sql","ocaml":"text\/x-ocaml","pascal":"text\/x-pascal","perl":"perl","perl6":"perl","plsql":"sql","properties":"text\/x-properties","q":"text\/x-q","scala":"scala","scheme":"text\/x-scheme","tcl":"text\/x-tcl","vb":"text\/x-vb","verilog":"text\/x-verilog","yaml":"text\/x-yaml","z80":"text\/x-z80"}