Please write the code in MATLAB. Your answer is appreciated!
Attach File. Use the following unit conversion: 1 lb = 0.45359 kg. Convert from kg to pound.
QUESTION 1:
Browse My Computer.
In the function body, if the second input argument is 1, then convert from pound to kg. If the second input argument is 2, then choice. The function accepts 2 input arguments. One is the weight and the other input is either 1 or 2.
Write the function, fn_convW, which converts the weight unit either from pound to kg or kg to pound depending on the user's choice.