This is my code. I want that when the person put the value 0, the message print ONLY "Negative,has not being infected". But instance it give also the hour of being infected.
x= input ('Enter x: '); %Degree of reaction to the virus from a blood test.
if x==0 disp ('Negative, has not being infected.') N=0;elseif x<=11 N= 3*x + 36;elseif x > 11 && x<=33 N= x*x - 10;elseif x > 33 && x<=64 N= x-6; endfprintf('\n%g hours of being infected.\n',N)
Best Answer