MATLAB: Calculate the sin and cos of a value in radians (in one function)

matlab function

I attempted to answer the question but I'm not sure if this is considered to be one function.
b = input('Enter a value ');
x=sin(b); y=cos(b);
disp('The sin of that value is ');
disp(x);
disp('The
cos of that value is ');
disp(y);

Best Answer

function sincos()
b = input('Enter the angle value in radians: ');
x=sin(b); y=cos(b);
fprintf('The sin of value %f is %f\n',b,x);
fprintf('The cos of value %f is %f\n',b,y);