October 31st, 2013, 01:17 PM
Unit conversion (switch)
I need to write a program using switch statement.
User needs to convert regular unit to S1 unit. User can choose length, volume or force for the conservation.
Note that foot=0.3048 m, 1 cubic foot=0.002817 cubic meter, 1 pound =4.4482 newtons.
So i need to write a pseudocode and need to test the program by entering the length of 3 feet, 2.5 cubic feet and 3.5 pounds.
October 31st, 2013, 01:36 PM
October 31st, 2013, 01:58 PM
Write a program using switch statement and write its pseudocode based on the information given
October 31st, 2013, 02:10 PM
Simple enough; carry on.
Come back when you have a problem.
October 31st, 2013, 04:32 PM
I think you should work with fundamental units. For instance, volume is length cubed. Specifying conversion factors for volume and for length doesn't quite sit right. On the other hand, if you don't know that volume is length cubed you'd need separate factors.
[/code] are essential for python code and Makefiles!