Check sibling questions

Write a function to calculate volume of a box with appropriate default values for its parameters. Your function should have the following input parameters:

a) Length of box   

b) width of box

c) height of box

 

Answer:

The function will be as follows:

def box_volume (l= 1 ,b= 1 ,h= 1 ):

    vol=l*b*h

    return (vol)

Are ads bothering you?

CA Maninder Singh's photo - Expert in Practical Accounts, Taxation and Efiling

Made by

CA Maninder Singh

CA Maninder Singh is a Chartered Accountant for the past 12 years. He also provides Accounts Tax GST Training in Delhi, Kerala and online.