I am sorry to bother that I am a rookie in using matlab. I can't even run the function. What should be fixed? Please give a help.
Write a MATLAB function named “cone” to accept inputs r and h, and return output V, where r, h, and V are respectively the radius, height, and volume of a cone.
function[V] = cone ( r, h )
Edit by Rik (moved from 'answer'):
The second question is:
Write a MATLABscriptto generate data and plot the function y = 1/xas shown below. The plot is in greencolourwith diamondmarkers.
but i can only get this graph by this script: