% MyTrig with ifs and input statements
% clean up
clear all;
close all;

% get values from user
angle = input('Please enter the angle you wish to compute: ');
degORrad = input('Please enter a 0 if your angle is in degrees and 1 if in radians: ');

% compute the sin/cos
if degORrad == 0
    sin_comp = sind(angle);
    cos_comp = cosd(angle);
else
    sin_comp = sin(angle);
    cos_comp = cos(angle);
end

% display results
fprintf('The sine of your angle is: %0.4f\n',sin_comp);
fprintf('The cosine of your angle is: %0.4f\n',cos_comp);