I have created a function file for the area of a circle, but I also need to include a prompt asking for the units of the radius. I also need to have the output area be expressed in the proper units, but am unsure of how to do either. This is what I have —
function [area] = area_circle(radius)area = pi.*radius.^2;end
Best Answer