Answered step by step
Verified Expert Solution
Question
1 Approved Answer
The part of this I can't complete is converting the input string of the temperature to a numeric value that can be used by the
The part of this I can't complete is converting the input string of the temperature to a numeric value that can be used by the tF method. This is the work I have so far.
function [tF] = convertC(tC)
calctC = input('Enter Temperature ', 's');
convert = datenum(calctC,'s');
age = datestr(now-convert ,'s');
tC = age(end, end);
switch nargin
case 0
error('No initial temperature defined')
end
tF = ((9/5*tC)) + 32;
fprintf('%2.2f degrees F');
end
Write a function to convert C to Fin degrees. Test the function for 0C, 100C. Include an error message into function if a temperature is not inputtedStep by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started