Question: plz type it for me ECE 296- Homework- Default ECE 296 Homework 2 Write a function that will calculate either the area of a square

plz type it for me
ECE 296- Homework- Default ECE 296 Homework 2 Write a function that will calculate either the area of a square or the volume of a cube based on the parameters passed to it. If only length and width are passed, the height should default to one using a default parameter. The function should use the same formula to calculate both quantities. The result should be returned in a tuple with the second part being the units (we will use feet to be consistent between everyone's code). 1. Ex: calc(2,5) would return (10, 'sq ft') calc(2,5,3) would return (30, 'cu ft')
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
