SHARE
TWEET

Untitled

a guest Mar 26th, 2019 59 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. <html>
  2. <head>
  3. <title>Zadanie</title>
  4. </head>
  5. <body>
  6. <?php
  7. class prostopadloscian
  8. {
  9.     public $pole;
  10.     public $objetosc;
  11.     public $a;
  12.     public $b;
  13.     public $h;
  14.    
  15.     function pole(){
  16.    
  17.         $pole = 2*$this->a*2*$this->b+2*$this->b*2*$this->h+2*$this->a*2*$this->h;
  18.         return $this->pole;
  19.     }
  20.  
  21.  
  22.  
  23. }
  24.     $c=new prostopadloscian();
  25.     $c->a=200;
  26.     $c->b=200;
  27.     $c->h=100;
  28.     print ($c->pole());
  29.     print("Długość:".$c->a."<br>");
  30.     print("Szerokość:".$c->b."<br>");
  31.     print("Wysokość:".$c->h);
  32. ?>
  33. </body>
  34. </html>
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Not a member of Pastebin yet?
Sign Up, it unlocks many cool features!
 
Top