You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
"cell_type":"markdown","source":["**It has a constructor**\n","\n","**It is used to get Total Surface area, Lateral Surface area, Volume, length of Diagonal and a execution method**\n","\n","### __init__\n","\n","It takes length, breadth and height of Cuboid \n","```python \n","from Lib.shapes import *;\n","len: float = 9;\n","brea: float= 8;\n","hei: float = 7;\n","cuboid: Cuboid = Cuboid(len, brea, hei);\n","```\n","\n","### TotalSurfaceArea\n","\n","it returns Total Surface area of Cuboid which is \n","\n","$2×(l×b + l×h + h×b)$\n","\n","```python\n","print(cuboid.TotalSurfaceArea())\n","```\n","`382`\n","\n","### LateralSurfaceArea\n","\n","it returns Lateral Surface area of Cuboid which is $2×(l + b)× h$\n","\n","```python\n","print(cuboid.LateralSurfaceArea())\n","```\n","`238`\n","\n","### Volume \n","\n","it returns Volume of Cuboid which is $l×b×h\\$\n","\n","```python\n","print(cuboid.Volume())\n","```\n","`504`\n","\n","### lengthofDiagonal\n","\n","it return length of Diagonal of Cuboid which is $\\sqrt{l² + b² + h²}\\$\n","\n","```python\n","print(cuboid.lengthofDiagonal())\n","```\n","`13.92`\n","\n","### execution\n","\n","it prints the value returned by TotalSurfaceArea, LateralSurfaceArea, Volume, lengthofDiagonal \n","\n","```python\n","cuboid.execution()\n","```\n","```\n","Total Surface area: 382\n","Lateral Surface area: 238\n","Volume: 504\n","Length of Diagonal: 13.92\n","```\n","\n","## Cube"],"metadata": {
"cell_type":"markdown","source":["**It has a constructor**\n","\n","**It is used to get Total Surface area, Lateral Surface area, Volume, length of Diagonal and a execution method**\n","\n","### __init__\n","\n","It takes side of Cube\n","\n","```python \n","from Lib.shapes import *;\n","side: float= 8;\n","cube: Cube = Cube(side);\n","```\n","\n","### TotalSurfaceArea\n","\n","it returns Total Surface area of Cube which is $6 × a²\\$\n","\n","```python\n","print(cube.TotalSurfaceArea())\n","```\n","\n","`384`\n","\n","### LateralSurfaceArea\n","\n","it returns Lateral Surface area of Cube which is $4 × a²\\$\n","\n","```python\n","print(cube.LateralSurfaceArea())\n","```\n","`256`\n","\n","### Volume \n","\n","it returns Volume of Cube which is $a³\\$\n","\n","```python\n","print(cube.Volume())\n","```\n","\n","`512`\n","\n","### lengthofDiagonal\n","\n","it return length of Diagonal of Cube which is $\\sqrt{3} × a$\n","\n","```python\n","print(cube.lengthofDiagonal())\n","```\n","`13.84`\n","\n","### execution\n","\n","it prints the value returned by TotalSurfaceArea, LateralSurfaceArea, Volume, lengthofDiagonal\n","```python\n","cube.execution()\n","```\n","```\n","Total Surface area: 384\n","Lateral Surface area: 256\n","Volume: 512\n","Length of Diagonal: 13.84\n","```\n","\n","## Sphere"],"metadata": {
"cell_type":"markdown","source":["**It has a constructor**\n","\n","**It is used to get Surface area, Volume and a execution method**\n","\n","### __init__\n","\n","It takes radius of Sphere\n","\n","```python \n","from Lib.shapes import *;\n","radius: float= 7;\n","sphere: Sphere = Cube(side);\n","```\n","\n","### SurfaceArea\n","\n","it returns Surface area of Sphere which is\n","$4 × π × r²$\n","\n","```python\n","print(sphere.TotalSurfaceArea())\n","```\n","\n","`615.44`\n","\n","### Volume \n","\n","it returns Volume of Sphere which is $4/3 × π × r³\\$\n","\n","```python\n","print(sphere.Volume())\n","```\n","\n","`1798.6234`\n","\n","### execution\n","\n","it prints the value returned by SurfaceArea, Volume\n","```python\n","sphere.execution()\n","```\n","```\n","Surface area: 615.44\n","Volume: 1798.6234\n","```\n","\n","## Cylinder"],"metadata": {
"cell_type":"markdown","source":["**It has a constructor**\n","\n","**It is used to get Total Surface area, Curved Surface area, Volume and a execution method**\n","\n","### __init__\n","\n","It takes radius and height of Cylinder\n","\n","```python \n","from Lib.shapes import *;\n","radius: float= 7;\n","height: float= 3;\n","cylinder: Cylinder = Cylinder(radius, height);\n","```\n","\n","### TotalSurfaceArea\n","\n","it returns Total Surface area of Cylinder which is $2 × π × r × (h + r)$\n","\n","```python\n","print(cylinder.TotalSurfaceArea())\n","```\n","\n","`439.6`\n","\n","### CurvedSurfaceArea\n","\n","it returns Curved Surface area of Cylinder which is $2 × π × r × h\\$\n","\n","```python\n","print(cylinder.CurvedSurfaceArea())\n","```\n","`131.88`\n","\n","### Volume \n","\n","it returns Volume of Cylinder which is $π × r² × h\\$\n","\n","```python\n","print(cylinder.Volume())\n","```\n","\n","`461.58`\n","\n","### execution\n","\n","it prints the value returned by TotalSurfaceArea, CurvedSurfaceArea, Volume\n","```python\n","sphere.execution()\n","```\n","```\n","Total Surface area: 439.6\n","Curved Surface area: 131.88\n","Volume: 461.58\n","```"],"metadata": {
0 commit comments