Skip to content

j0hnd/Assignment-Shapes

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

35 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Assignment

Complete the run.php script so it outputs the total area and total volume for the array of shapes. The shapes are both 2D and 3D.

To Do

  • Create a cube object and a sphere object.
  • Add the cube and sphere to the run.php script.
  • The total area is the sum for the area of each shape.
  • The total volume is the sum for the volume of each 3D shape. Ignore 2D shapes from the array.
  • Create PHPUnit tests for each class file.

Requirements

You will require php 5.6 and the latest installation of PHPUnit.

PHPUnit

You need to have the latest PHPUnit installation. A phpunit.xml file is already setup. An ExampleTest.php file is provided in the tests directory. After installing PHPUnit, simply run phpunit on the command link to run your tests.

About

Calculate the area of shapes

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • PHP 100.0%