Question: Write a Python script that converts between different units of pressure. It should be able to convert units of Papa, kPakPa, MPaMPa, atmatm, psipsi, lbfftzlbfft2,

Write a Python script that converts between different units of pressure. It should be able to convert units of Papa, kPakPa, MPaMPa, atmatm, psipsi, lbfftzlbfft2, torrtorr, inHginHg, and mmHgmmHg. Name the function presscon. Run the code below to test the function your created. In your homework include your function as well as the output of the script below. Note: import pressure converter as pc pressure = 200 units = ['Pa', 'kPa', 'MPa', 'atm', 'psi', 'Ibf/ft2', 'torr', 'inHg', 'mmHg', 'K'] print('input Unit\t\tOutput Unit\tValue') for input_unit in units: for output_unit in units: message = input unit + '\t' + output_unit + '\t' message += strips:pressure Con(pressure, input_unit, output_unit)) print(message)
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
